Skip to content

Commit

Permalink
Merge branch 'major_refactor' of https://github.com/mierenmanz/byte_type
Browse files Browse the repository at this point in the history
 into major_refactor
  • Loading branch information
MierenManz committed Nov 13, 2023
2 parents 8fa27f1 + d028552 commit fc2a01b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/compound/tagged_union.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export class TaggedUnion<
#variantFinder: Fn<V>;
#discriminant: AlignedType<number>;

constructor(input: T, discriminantCodec: AlignedType<number>, variantFinder: Fn<V>) {
constructor(input: T, variantFinder: Fn<V>, discriminantCodec: AlignedType<number> = u8) {
// Find biggest alignment
const byteAlignment = Object.values(input)
.reduce((acc, x) => Math.max(acc, x.byteAlignment), 0);
Expand Down

0 comments on commit fc2a01b

Please sign in to comment.