mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
parent
f5e97ef1b5
commit
9c11781880
20 changed files with 25 additions and 29 deletions
|
@ -50,7 +50,7 @@ impl ByteString {
|
|||
/// [RFC 2616](http://tools.ietf.org/html/rfc2616#page-17).
|
||||
pub fn is_token(&self) -> bool {
|
||||
let ByteString(ref vec) = *self;
|
||||
if vec.len() == 0 {
|
||||
if vec.is_empty() {
|
||||
return false; // A token must be at least a single character
|
||||
}
|
||||
vec.iter().all(|&x| {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue