hat invisible whitespace characters
that some editors don't even let you type are particularly
beginner-hostile, whereas allowing undef arguments where they don't make
sense (and hence where callers don't generally try supplying undef) is
something that many Perl 5 programs have been doing for years with no
widespread harm.
Cheers
Smylers
--
http://twitter.com/Smylers2
Aristotle Pagaltzis writes:
> Just because you can’t think of the use of a feature doesn’t mean
> there isn’t one.
No, though it possibly means the docs could do with a clearer example
which demonstrates its use in a situation where it makes sense to use
it.
Smylers
--
http://twitt
pened to include some Python
along the way. (This was over 10 years ago, when Python wasn't as
widespread or recognized as it is now.)
I think that over time the amount of Python increased.
So maybe the situation isn't completely without hope.
Smylers
--
Why drug companies shouldn'
Larry Wall writes:
> On Tue, Jul 24, 2012 at 09:42:10PM +0100, Smylers wrote:
>
> : Under what circumstances is tcuc useful? I'm currently suffering
> : from a lack of imagination as to when somebody would ever want that
> : rather than just uc.
>
> A bare uc will
lc, and tcuc),
Under what circumstances is tcuc useful? I'm currently suffering from a
lack of imagination as to when somebody would ever want that rather than
just uc.
Cheers
Smylers
--
http://twitter.com/Smylers2
hing? That is, Perl
6 always interprets illo-figut and illo_figut as being the same
identifier (both for its own identifiers and those minted in programs),
with programmers able to use either separator on a whim?
That would seem to be the most human-friendly approach.
Smylers
--
http://twitter.com/Smylers2
situation, and where the Perl 6 operator
that Does The Right Thing is spelt the same as the Perl 5 operator that
I'm used to; that muddles the distinction you make above about matching
ranges versus generating lists.
Smylers
--
http://twitter.com/Smylers2
opy pasta or am
I missing something?
Cheers
Smylers
--
http://twitter.com/Smylers2
list value rather than calling it:
I think "arrange return" needs a "to" in the middle.
Smylers
--
Watch fiendish TV quiz 'Only Connect' (some questions by me)
Mondays at 20:30 on BBC4, or iPlayer: http://www.bbc.co.uk/programmes/b00lskhg
right and evaluates them as lazily as possible to produce the desired
> +series of values. The lists are evaluated as flat lists.
"Takes a left" -- is this the satnav operator?
Smylers
--
Connecting walls made up by me now on the BBC -- this week's 'Only Connect',
re.)
Thanks.
Smylers
--
Watch fiendish TV quiz 'Only Connect' (some questions by me)
Mondays at 20:30 on BBC4, or iPlayer: http://www.bbc.co.uk/programmes/b00lskhg
ode?
> > Let's see what others think.
>
> OK.
I like the braces. I suggest initially only providing for braces, but
with the possibility of later adding options to indicate other
termination points if in practice there turn out to be many situations
where the braces don't work well.
Smylers
and is familiar to many users from other software
which follows that convention.
Indeed others (including S19) already seem to believe that two hyphens
are needed:
jerry gay writes:
> this is why it's spelled 'perl6 --doc'
Smylers
_>, on the grounds that everything always
aliases to C<$_>.
What's the argument for it being C<@_>?
Smylers
verload an existing operator for
> +"off topic" uses.
I'm wondering if something similar should apply to C<-->; that string
and numeric decrement are different, so should have different operators.
Smylers
s a Capture object - see S02
Does the variable name in the comment need changing too?
Smylers
hows the
> correspondence of these forms?
Those three _are_ all the same thing, in that they all generate pairs.
The colon can _also_ be used for forming adverbs (similarly to how the
slash can be used for both regexes and division, in different places),
but that doesn't effect the equivalence of the above.
Smylers
cdumont writes:
> Smylers wrote:
>
> > cdumont writes:
>
> > > The given ... when doesn't seem to bring that much from switch ...
> > > case given ...
> >
> > Surely it brings all of it? Plus much more as well. Much of the
> > powe
behind it and the
community as a whole chooses it, not because somebody named it as such.)
Smylers
ody writes the Grammar::JSON module -- but
the whole point of Perl 6's pluggable grammars is that it specifically
supports people who want to do this sort of thing: it recognizes that
not everybody is going to agree on the ideal syntax, so instead it
merely provides a 'default' syntax (which Larry judges to be the best
all-round) then provides a way of changing anything about it.
Hope that helps.
Smylers
h XML
In Perl 5 would it've been good to add XML::Parser to the core as soon
as it was written, and ecouraged everybody to standardize on using that
rather than coming up with others?
Smylers
core which I see as
> being an advantage over other languages;
Ah, well that's where you've seriously misunderstood the situation, I'm
afraid.
The deal here is that we have bits in the core which _Larry_ sees as
being advantageous over other languages! (And the rest of us tag along
because we like the decisions he makes.)
Smylers
XHTML1 launched did you correctly predict that XHTML2 would turn
into an ignored project that no web-browser vendors are interested in
implementing, and that instead they would be implementing HTML5, a
language based on HTML4 that encourages authors not to bother with XML?
If you didn't predict that, how does it fit in with your claim that you
"can only see more XML for all of us"?
Smylers
[EMAIL PROTECTED] writes:
> -A leading C<[> or C<+> indicates an enumerated character class. Ranges
> +A leading C<[> indicates an enumerated character class. Ranges
> in enumerated character classes are indicated with "C<..>" rather than
> "C<->".
>
> / <[a..z_]>* /
> - / <+[a..z_
arameter(s), and the
short description of what it does, it's obvious what the parameter(s)
are for and what it returns; repeating that information doesn't help
anybody.
(It may help computers, though.)
Smylers
Darren Duncan writes:
> At 11:23 PM +0100 6/21/07, Smylers wrote:
>
> > Has Larry yet decreed whether Web will be bundled with Perl 6?
>
> I believe that what Larry has said is that there are no official core
> modules, ... So ... not something to worry about now.
Th
Juerd Waalboer writes:
> Smylers skribis 2007-06-21 23:23 (+0100):
>
> > Of course. But there's a big difference between the attitude of
> > 'let's do the best we can right now' and 'this is our one chance to
> > do this right'.
>
>
Moritz Lenz writes:
> Smylers wrote:
>
> > Moritz Lenz writes:
> >
> > > Web is hopefully "CGI done right"
> >
> > ... why are we hoping that it will be "done right"?
>
> Because we hope we learned from the past. There are s
Juerd Waalboer writes:
> Smylers skribis 2007-06-21 21:33 (+0100):
>
> > I disagree. perldoc.perl.org was started by JJ, gained popularity,
> > and then got awarded the official blessing of the onion. Over the
> > years there have many several sites with Perl documen
6.0.0 on all my computers to be
able to use it; but if Perl 6.0.1 has improved documentation then I can
read, browse, and search that documentation on its website without
needing to upgrade any of my computers.
Smylers
e (so that
by the time you've reached the code you already know what it's supposed
to be doing) -- but I'm not adamant about continuing with this style.
Smylers
Darren Duncan writes:
> At 6:37 PM +0100 6/21/07, Smylers wrote:
>
> > Web module? This is the first I've heard of it. Where is it being
> > planned, if not on this list?
>
> It was being discussed on the perl6-users list, last year.
Thanks.
Smylers
where this does happen, making the learner in question
irritated (with either the trainer for not mentioning it, or the
language for having this exception).
Neither of those are ideal.
> You don't need to understand POD to read a program where POD is used :
> it's usually qui
. Hence there is no paragraph
> or delimited form of the C<=encoding> directive (just as there is no
> paragraph or delimited form of C<=begin>).
I was with you right up until the mention of C<=encoding>; what's that
got to do with anything?
Smylers
brian d foy writes:
> In article <[EMAIL PROTECTED]>, Smylers
> <[EMAIL PROTECTED]> wrote:
>
> > brian d foy writes:
> >
> > > In article
> > > <[EMAIL PROTECTED]>, Damian
> > > Conway <[EMAIL PROTECTED]> wrote:
> >
against the light of available evidence!
It seems entirely possible that during Perl 6's life somebody, possibly
somebody who at the moment hasn't even heard of Perl 6, will create a
better web module. It would be good if at that point it becomes
straightforward for it to get acceptance and people to adopt it.
Smylers
n my program.
Testing is another area which has had immense progress since the release
of Perl 5. Look at where Test::More, Test::Class, TAP::Parser and so on
are now; we certainly wouldn't want to be restricted to a standard of
best practices in testing from the early 1990s.
Smylers
Mark Overmeer writes:
> * Smylers ([EMAIL PROTECTED]) [070616 09:09]:
> >
> > You're concerned that an aspect of Perl 6 might have too much
> > freedom? Isn't Perl all about giving users freedom to choose their
> > own way of doing something?
>
>
as well. What on earth
is that for?
Until it twigged. If I hadn't read the spec then everything would just
have worked naturally!
Smylers
Mark Overmeer writes:
> * Smylers ([EMAIL PROTECTED]) [070616 08:44]:
>
> > With these new Pod rules it's possible to entirely remove Pod from a
> > file without knowing _anything_ about the host language. That
> > permits Pod to be used to document just about
is considered Pod by any standard Pod
> parser, but is *not* considered Pod by the Perl 6 parser. And I think
> that's just fine.
I like it!
Is that a decision yet, or were you just thinking out loud?
Smylers
also don't tie
ourselves into anything.
If a particular convention gains widespread approval then peer pressure
should encourage its use (in the same way that strict and warnings are
currently optional in Perl 5, but in the absence of a good reason it's
expected that they be used).
Smylers
ders of magnitude more complex than the
simplicity of filtering off all Pod first, and strikes me as something
other languages are much less likely to be bothered to do.
Smylers
oh, those block comments look nifty -- and are inspired way of
avoiding surprising people just putting hashes at the beginning of all
their lines of code.
Smylers
ething more generic.
Nah, the current name is good: it has the convenient mnemonic of being
the name that people "object" to ...
Smylers
a programmer really needs to open
something but doesn't know wether that thing is a file, a directory, or
a URL? I'm still unpersuaded this is sensible default behaviour.
Smylers
[Apologies for the delay on this; I first tried to send it on April
15th, and only just spotted it failed to get through.]
some memory of previously establishing the link is one-way,
and that posting using the Google Groups interface doesn't result in
your mail reaching the list elsewhere.)
Smylers
ams open a file from a name specified by the user. Even if
C existed, many programmers would surely continue to use
C for this.
Users being able to trick such programs into opening a directory rather
than a file could be unpleasant.
Smylers
Larry Wall writes:
> On Mon, Mar 12, 2007 at 10:20:12PM +0000, Smylers wrote:
>
> : [EMAIL PROTECTED] writes:
> :
> : > Separated clobbering <== ==> from pushy <<== and ==>>
> : >
> : > +Feeding into the C<*> "whatever" term sets
angle:
> +
> +0..* ==> *;
> +'a'..* ==>> *;
> +pidigits() ==>> *;
Can you append to something that isn't there? Would it matter if the
first feed also had a double pointy bracket on it?
Smylers
Larry Wall writes:
> On Thu, Mar 08, 2007 at 09:05:32AM +0000, Smylers wrote:
>
> : So I fear that people will do the same thing in Perl 6. Which,
> : initially, will appear to work. But then, some months later,
> : somebody upgrades the installed version of a module (or the p
| 1.3.4):auth(/:i jrandom/);
> > +use Dog:ver(Any):auth({ .substr(0,5) eq 'cpan:'})
>
> > +use Perl:ver(v6..*):auth(Any);
>
> Seems accidentally to me.
Those are all ranges or code that specifies which values are permitted,
rather than literal values.
Smylers
[*0] And I recognize from the lack of leading "+" symbols on the text
it isn't a recent change; my apologies for not spotting it earlier.
Smylers
ssing that requires this functionality I
don't see why loading a module would be too much of a burden.
> In conclusion, I consider functionality like relational-join to
> provide considerable conciseness to very common data processing
> operations
Are there Cpan modules in existence for doing this kind of thing in Perl
5?
Smylers
ons
(results from function calls, delving deep into very nested data
structures, whatever) could be tedious. Repetition is certainly poor
style and makes the code more prone to errors being introduced.
Also, it relies on the contents of C<@rray> not being cleared inside the
loop.
Smylers
..
> > }
>
> I'd say that or a close variation of it was a pretty common idiom.
I've many times wanted a better way of doing that too. Basically you
want an C to attach to the C but only be activated if none of
the. Larry's suggestion of using C for this looks good.
Smylers
about this operator would
correctly infer its existence from other operators? Even if somebody
guessed that both operators exist it looks pretty arbitrary which is
which.
For this esoteric sort of stuff can't we have named operators (short
names if you like, perhaps taken from assembly language), in a module
that can be loaded by those who need them?
Smylers
unctions that they actually use.
Note that being in a module doesn't (necessarily) mean 'not distributed
with core Perl'.
> 1. join() aka natural_join():
Remember that Perl already has a C function, for joining strings.
Smylers
Jonathan Lang writes:
> Smylers wrote:
>
> > Richard Hainsworth writes:
> >
> > > When does the specification of perl6 come to an end?
> >
> > At a guess: when it's implemented.
> >
> > Many of the recent changes have been made by Larry
7; threads on this
list, proposing brand new features, but nowhere near as many as there
used to be. And at least some of us are trying to discourage such
things, hoping to deflect them away from taking Larry's time away from
getting finished synthesizing what we already have -- especially in the
case of things which could easily be provided by a module.
Smylers
ets to differ between the long
and short forms for arrays and hashes?
Smylers
27; read-only than
C<$TEMPERATURE> does? Would you also be able to declare a separate
(presumably read-write) variable, C<$temperature> in the same scope as
C<$-temperature>?
Smylers
Jonathan Scott Duff writes:
> On 2/6/07, Smylers <[EMAIL PROTECTED]> wrote:
>
> > Blair Sutton writes:
> >
> > > David Green wrote:
> > >
> > > > In some ways, I like not having a [0] index at all: programmers
> > > > may be used
al around;
having the Perl 6 idiom for that involve a temporary array seems rather
ugly, exactly the sort of awkwardness that Perl 6 is eliminating
elsewhere.
Smylers
tion +1 inside [] operators instead; maybe this
> could be accessible via a Perl "use" pragma.
Hmmm, a pragma's a bit heavyweight for this; how about being able to set
this with a special global variable -- that sure sounds handy ...
Smylers
ng
tests, test frameworks, and things that relate to testing. Which this
isn't.
(But I have't got a suggestion for a better name.)
Smylers
Carl Mäsak writes:
> my $foo;
> # ...later in the same scope...
> my $foo; # illegal Perl5, legal Perl6
That isn't illegal in Perl 5. It yields the warning:
"my" variable $foo masks earlier declaration in same scope
but it does work.
Smylers
TSa writes:
> Smylers wrote:
>
> > I'd much prefer for introductory Perl books not to have to explain
> > what "Euclidean" means.
>
> Yeah, it will not dive into the exact reasons why the floor
> definition was chosen, either.
Sure, if we _only_ have
have to explain what "Euclidean" means.
> Everything else could be loadable from a module.
I still reckon a single type of division is sufficient in core, with
everything else in modules.
Smylers
an.
Triple-yay!
Smylers
gers:
% perl -wle 'print 99 / 2'
49.5
How would you get the current Perl 5 behaviour of displaying fractional
parts if they exist and not if they don't?
Smylers
ntation just a little bit fatter.
By all means have them available as modules. Presumably people who need
this stuff in Perl 5 have already created Cpan modules providing them,
and the same will happen in Perl 6.
Smylers
s means to invoke a
different method in place of the current one; nextsame and nextwith are
related to the latter meaning.
Won't that be confusing? Or hard to teach?
The 'loop' use of C is likely to be encountered by learning
programmers far earlier than 'method' use, leaving the latter as
something to trip them up when they finally meet it.
Smylers
s like we can reopen a
class:
It seems unlikely that the syntax is final if the feature is only being
mooted as "might be possible" (and the rest of Larry's message wasn't
exactly enthusiastic about the idea).
Smylers
Jonathan Lang writes:
> For the record, I think that "superdoes" should be spelled "done_by".
I think it's unlikely that Larry will incorporate any keywords that
contain underscores -- certainly not without at least searching for a
single word that sums up the concept in question.
Smylers
if $_.keys === $x
> +Set Set members identicalmatch if $_ === $x
> +Hashany(Hash) hash key intersectionmatch if exists
> $_{any(Hash.keys)}
Should that last one have a C<$x> in the code somewhere?
Smylers
TSa writes:
> I want to propose the addition of a Bag type
Different from the C that's already mentioned in Synopsis 3?
Smylers
etc.
>
> I don't think that will work out. Modification of a Set is more
> complex than modification of a Bag, so in that sense the Bag is the
> main type.
Is this still the Perl 6 _Language_ group? The one where we consider
what Perl 6 will do, and leave the implementation details to others?
Smylers
This feature is used often enough in Perl 5 classes, and I'm
almost certain there are no plans to remove it from Perl 6.
Smylers
$baz = $bar * 17; my $quux = $baz - 3; $baz / $quux };
Sure there are variables. But in terms of how your brain thinks about
it is it any different from the functional version -- labels being
associated with intermediate parts of the calculation?
Smylers
ersion +^$a == -1 - $a holds? Note that -1 == +^0.
Does that assume a two's complement system? Is that a safe assumption
to make about everywhere Perl 6 will run? (Is it even a safe assumption
to make about Perl 5?)
> Note further that in infinite precision the arithmetic shift left
> maintains the sign ...
Do we expect Perl 6 to be running on infinite-precision systems?
Smylers
supporting Larry's
suggestion that this is confusing, with some people expecting it to work
exactly opposite to how it does.
It doesn't really matter which way is right -- merely having some people
on each side, all naturally deriving what makes sense to them -- shows
that implementing this would cause much confusion.
Smylers
picking-and-choosing what they want from other programming
> languages.
Yes, but not from the source of their implementation. (At least, not
from the source of any which don't have a licence explicitly permitting
doing so.)
Smylers
Trey Harris writes:
> In a message dated Wed, 4 Oct 2006, Smylers writes:
>
> > Trey Harris writes: T
> >
> > > I remember not so many years ago when there were a lot of modules
> > > floating around that required you to do "no strict"
L 4 spec:
http://www.w3.org/TR/REC-html40/sgml/entities.html
Smylers
Jonathan Lang writes:
> Smylers wrote:
>
> > Jonathan Lang writes:
> >
> > > Translating this to perl 6, I'm hoping that perl6 is smart enough
> > > to let me say:
> > >
> > >s(pattern) { doit() }
> > >
> > > Inst
ly execute as code something which you just expected to be a
string. Not a good trap to have in the language.
Smylers
;. (I won't name
> names, because some of their authors post to this list ;)
Again, I can't see how. If you use C in your program then
it is lexically scoped and only affects your code, not that of other
files you load in.
C<-w> does affect all files, but that's one of the reasons why C is an improvement over C<-w>, because it lets the author of
each bit of code have control over it.
Smylers
of thing?
>
> use strict;
That's different: it's _you_ that's forbidding things that are otherwise
legal in your code; you can choose whether to do it or not.
Jonathan's examples were all of _somebody else_ forbidding you from
doing otherwise-legal things; you have this imposed on you without
choice.
Smylers
Larry Wall writes:
> Conjecture: We need a corresponding sigil to request captureness. As
> Bikeshed: What should that sigil be?
What's * doing these days?
Smylers
Randal L. Schwartz writes:
> >>>>> "Smylers" == Smylers <[EMAIL PROTECTED]> writes:
>
> Smylers> No: no aliases. Perl does not have a tradition of these,
>
> except "for"/"foreach". :)
I don't reckon one instance is en
to filter many
things other than lists.
The above are not conclusive reasons why we shouldn't rename C to
C (I'm not that bothered either way myself), but just some
points to bear in mind and reasons to be cautious.
Smylers
in Perl 6, regardless of what
the docs say.
I do not think renaming C to C is a terrible idea, but if
it's being done then it should be done properly, not half-heartedly with
an alias.
Smylers
[EMAIL PROTECTED] writes:
> New Revision: 11504
>doc/trunk/design/syn/S02.pod
>
> +C<< ('foo','bar') >>. Since parentheses are generally reserved just for
> +precedence grouping, they merely autointepolate in list context. Therefore
Typo: "autointepolate".
Smylers
David Green writes:
> On 8/13/06, Smylers wrote:
>
> > Please could the proponets of the various behaviours being discussed
> > here share a few more concrete examples ...
>
> OK,
Thanks for that. In summary, if I've understood you correctly, it's
that:
=
C< [1, 2] > looks like
it's its own thing that won't be equal to another one.
Smylers
On July 14th Yuval Kogman wrote:
> On Fri, Jul 14, 2006 at 11:42:24 +0100, Smylers wrote:
>
> > I'm afraid I still don't get it.
> >
> > Or rather, while I can manage to read an explanation of what one of
> > these operators does and see how it applies t
[EMAIL PROTECTED] writes:
> s/loop/repeat/ for test-after loops
Yay! That makes things very clear, with different things looking nicely
different.
Smylers
e to this by putting a space-eating
backslash after the closing brace:
loop
{
...
}\
while $x;
That still has the keywords and the braces aligned.
Smylers
ror.
If the sentence has no verb, a grammatical error.
Smylers
1 - 100 of 242 matches
Mail list logo