Commit 5790c55
authored
src: do not use non-static class member for constant value (#1134)
Non-static class members need to be set for each instantiated
object and take up extra space, which is why constant data
is generally provided through static members or static functions
(and static functions are a bit easier to use in header-only C++11).1 parent b7659db commit 5790c55
2 files changed
+12
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2607 | 2607 | | |
2608 | 2608 | | |
2609 | 2609 | | |
2610 | | - | |
2611 | | - | |
| 2610 | + | |
| 2611 | + | |
2612 | 2612 | | |
2613 | 2613 | | |
2614 | 2614 | | |
| |||
2648 | 2648 | | |
2649 | 2649 | | |
2650 | 2650 | | |
2651 | | - | |
2652 | | - | |
| 2651 | + | |
| 2652 | + | |
| 2653 | + | |
| 2654 | + | |
2653 | 2655 | | |
2654 | 2656 | | |
2655 | 2657 | | |
2656 | 2658 | | |
2657 | 2659 | | |
2658 | 2660 | | |
2659 | | - | |
| 2661 | + | |
2660 | 2662 | | |
2661 | 2663 | | |
2662 | 2664 | | |
| |||
2772 | 2774 | | |
2773 | 2775 | | |
2774 | 2776 | | |
| 2777 | + | |
| 2778 | + | |
| 2779 | + | |
| 2780 | + | |
2775 | 2781 | | |
2776 | 2782 | | |
2777 | 2783 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1720 | 1720 | | |
1721 | 1721 | | |
1722 | 1722 | | |
1723 | | - | |
1724 | | - | |
| 1723 | + | |
1725 | 1724 | | |
1726 | 1725 | | |
1727 | 1726 | | |
| |||
0 commit comments