buf() mishandles [3, 0, 0, 0, 0] #9
	
		Labels
		
	
	
	
	
	
	
		No Milestone
		
			
		
	
	
		
		
		
			No project
			
				
			
		
	
	
	
	
	
		No Assignees
		
			
		
	
	
	
		1 Participants
		
	
	
		
		
			Notifications
			
				
			
		
	
	
	
	Due Date
	No due date set.
			
				Dependencies
				
				
		
	
	
	No dependencies set.
			Reference: sheetjs/js-crc32#9
			
		
	
		Loading…
	
		Reference in New Issue
	
	Block a user
	
	No description provided.
		
		Delete Branch "%!s()"
	 
	Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Never mind … I didn’t realize this computes a signed value rather than unsigned.
"The return value is a signed 32-bit integer."
See the discussion from an older issue. Basically V8 has a special optimization for 32-bit signed integers which is generally awesome but performs extremely poorly for naive CRC calculations
Might be nice to include a convenience that does the signed-to-unsigned conversion?
I think it's just:
0xffffffff - ~signed?Even easier:
signed >>> 0:) kinda seems like a waste to add that as a convenience method, but it's probably worth adding that to the README (PRs welcome)