Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (* ttf.ml: *)
- let _nbits x =
- if x = 0 then
- 0
- else
- let x = ref x in
- if !x < 0 then x := -1 * !x;
- let nbits = ref 0 in
- while !x > 0 do
- x := !x lsr 1;
- incr nbits;
- done;
- !nbits
- (* ------------------------------------- *)
- (* swfparser.ml: *)
- let do_something_terrible_to_v n v
- v & ((1 << n ) - 1);
- let write_bits n v = write_bits n (do_something_terrible_to_v n v)
Advertisement
Add Comment
Please, Sign In to add comment