Skip to content

Commit 102188e

Browse files
committed
document the request for exported constant prefixes
1 parent fb33018 commit 102188e

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

TODO

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,30 @@ These changes are under consideration. They have not begun, and they
110110
may not ever be made. These are proto-plans being considered and made
111111
ready for deployment.
112112

113+
---------------------------------------
114+
Give Exported Constants Some Prefix(es)
115+
---------------------------------------
116+
117+
<Micksa> eep, poe uses yet another calling convention
118+
<Micksa> like:
119+
<Micksa> my ($kernel, $heap, $session) = @_[KERNEL, HEAP, SESSION];
120+
<Fletch> that's the normal convention, it just doesn't hardcode what
121+
order particular arguments will be passed
122+
<Micksa> it's, like, the 4th way I've seen so far for passing named
123+
parameters.
124+
<Fletch> it's so that if calling order ever changes programs that use
125+
the symbolic constants don't break
126+
<Fletch> it's really no different than say
127+
`my($kernel,$heap)=@_[0,3]', just that the 0 and 3 come from
128+
constant subs rather than magic numbers
129+
<Micksa> problem is, the symbolic constants are rather likely to
130+
clash.
131+
<Fletch> maybe there could be an option to prefix them, like
132+
poe_KERNEL or P_KERNEL?
133+
<Micksa> *shrug*
134+
135+
That sounds like a good idea.
136+
113137
-------------------------------------------
114138
Change Internal Helpers To Static Functions
115139
-------------------------------------------

0 commit comments

Comments
 (0)