Skip to content

Commit d033245

Browse files
authored
Merge pull request #255 from DominicChm/bugfix-pointer
Bugfix: Make `pointer` accept offset=0
2 parents 39912a8 + f7ac6a4 commit d033245

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/binary_parser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -706,7 +706,7 @@ export class Parser {
706706
}
707707

708708
pointer(varName: string, options: ParserOptions): this {
709-
if (!options.offset) {
709+
if (options.offset == null) {
710710
throw new Error("offset is required for pointer.");
711711
}
712712

0 commit comments

Comments
 (0)