mirror of
				https://github.com/meilisearch/meilisearch.git
				synced 2025-11-04 01:46:28 +00:00 
			
		
		
		
	chore: remove assert on Attribute::new()
This commit is contained in:
		@@ -105,9 +105,6 @@ impl WordArea {
 | 
				
			|||||||
    /// The byte index must not be greater than 2^22
 | 
					    /// The byte index must not be greater than 2^22
 | 
				
			||||||
    /// and the length not greater than 1024.
 | 
					    /// and the length not greater than 1024.
 | 
				
			||||||
    fn new(byte_index: u32, length: u16) -> Result<WordArea, WordAreaError> {
 | 
					    fn new(byte_index: u32, length: u16) -> Result<WordArea, WordAreaError> {
 | 
				
			||||||
        assert!(byte_index & 0b1111_1111_1100_0000_0000_0000_0000 == 0);
 | 
					 | 
				
			||||||
        assert!(length & 0b1111_1100_0000_0000 == 0);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        if byte_index & 0b1111_1111_1100_0000_0000_0000_0000 != 0 {
 | 
					        if byte_index & 0b1111_1111_1100_0000_0000_0000_0000 != 0 {
 | 
				
			||||||
            return Err(WordAreaError::ByteIndexTooBig)
 | 
					            return Err(WordAreaError::ByteIndexTooBig)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user