Commit c58ebb5
Fix Octave compatibility in Companion NotificationCenterPane
PR #180 introduced MATLAB-only classdef syntax that breaks the Octave
test suite: the class fails to load, taking test_notification_center_pane
down with it.
- Property type-constraint `IsAttached logical = false` (Octave classdef
has no inline type validation) -> plain default + comment.
- `Event.empty` property defaults and method assignments (no
ClassName.empty in Octave) -> `[]`, which behaves identically under
isempty / numel / indexing / concatenation in every use here.
- Comma-list expansion over classdef object arrays ([events.Severity],
[events.StartTime]) and arrayfun over them (Octave supports neither)
-> explicit index loops, matching the pane's existing text-filter loop.
Also drops Event.empty from the test double (StubEventStore) and the
test's empty-case assertion. Verified 18/18 pass in both Octave 7+
(octave-cli) and MATLAB R2020b+; mlint clean.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent 2a191c0 commit c58ebb5
3 files changed
Lines changed: 33 additions & 12 deletions
File tree
- libs/FastSenseCompanion
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
72 | | - | |
| 72 | + | |
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
| |||
232 | 232 | | |
233 | 233 | | |
234 | 234 | | |
235 | | - | |
| 235 | + | |
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
242 | | - | |
| 242 | + | |
243 | 243 | | |
244 | 244 | | |
245 | 245 | | |
| |||
353 | 353 | | |
354 | 354 | | |
355 | 355 | | |
356 | | - | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
357 | 363 | | |
358 | 364 | | |
359 | 365 | | |
| |||
640 | 646 | | |
641 | 647 | | |
642 | 648 | | |
643 | | - | |
| 649 | + | |
644 | 650 | | |
645 | 651 | | |
646 | 652 | | |
| |||
654 | 660 | | |
655 | 661 | | |
656 | 662 | | |
657 | | - | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
658 | 670 | | |
659 | 671 | | |
660 | 672 | | |
| |||
666 | 678 | | |
667 | 679 | | |
668 | 680 | | |
669 | | - | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
670 | 687 | | |
671 | 688 | | |
672 | 689 | | |
| |||
675 | 692 | | |
676 | 693 | | |
677 | 694 | | |
678 | | - | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
679 | 700 | | |
680 | 701 | | |
681 | 702 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| |||
0 commit comments