filler is whitespace.
Why's that a "problem"?
Folks want to be able to line stuff up, and to split statements over
multiple lines. This is now possible.
Smylers
Perl 6, whatever that is --
I've had a quick flick through the synposes and couldn't spot anywhere
that mentioned the obvious hooks for the Perl 5 C and C
subs.
Smylers
and sounds like the kind of thing that would
trip me up.
But this could just be because I don't (yet) grok scans.
Smylers
Markus Laire writes:
> On 5/9/06, Smylers <[EMAIL PROTECTED]> wrote:
>
> > But this could just be because I don't (yet) grok scans.
>
> Here's a simple example:
>[+] 1,2,3,4,5
> would return scalar 1+2+3+4+5 as a reduction and list (0, 1, 1+2,
>
Gaal Yahas writes:
> On Tue, May 09, 2006 at 11:23:48AM +0100, Smylers wrote:
>
> > So I have the list generated by the scan. And? What do I do with
> > it? I can't think of any situation in my life where I've been
> > wanting such a list.
>
> Scans
Mark A. Biggar writes:
> Austin Hastings wrote:
>
> > Gaal Yahas wrote:
> >
> > > list [==] 0, 0, 1, 2, 2;
> > > # bool::false?
> > > # (bool::true, bool::true, bool::false, bool::false, bool::false)
> >
> >(And I
already a sufficiently convenient way of doing this, and is
intuitive to the casual reader.
I think the effort in learning this special case outweighs any benefit
it brings.
Smylers
7;literal space'? Except they aren't
exactly literal, because they only indicate where _some_ space has to
be, not that it has to be exactly that sort of space.
What about :gappy, to indicate that there have to be gaps in the source
text at the points where there are gaps in the pattern?
Smylers
>
> >{...})
> >
> > Hashes don't interpolate in Perl 5, so that's not an issue
And Sage, please (in general) don't top-post on this mailing list; it
makes it much harder for people who wish to follow up on what was said
earlier in the thread to provide context for exactly what they're
commenting on.
Smylers
his used to be the same as but it no longer is"
probably only confuses the casual reader.
Smylers
t learners often stumble over. If we're going to have 5 of the
things in Perl 6 then there needs to be a very clear way of explaining
how to determine which one to use (or at least an explanation that 3 of
the operators are very esoteric and beginners don't need to worry about
them).
Smylers
Yuval Kogman writes:
> On Fri, Jul 14, 2006 at 11:42:24 +0100, Smylers wrote:
>
> > Or rather, while I can manage to read an explanation of what one of
> > these operators does and see how it applies to the variables in the
> > examples next to it, I am struggling to ret
ror.
If the sentence has no verb, a grammatical error.
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
[EMAIL PROTECTED] writes:
> s/loop/repeat/ for test-after loops
Yay! That makes things very clear, with different things looking nicely
different.
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
C< [1, 2] > looks like
it's its own thing that won't be equal to another one.
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:
=
[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
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
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
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
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
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
;. (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
ly execute as code something which you just expected to be a
string. Not a good trap to have in the language.
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
L 4 spec:
http://www.w3.org/TR/REC-html40/sgml/entities.html
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"
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
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
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
$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
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
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
TSa writes:
> I want to propose the addition of a Bag type
Different from the C that's already mentioned in Synopsis 3?
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
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
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
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
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
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
an.
Triple-yay!
Smylers
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
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
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
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
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
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
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
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
ets to differ between the long
and short forms for arrays and hashes?
Smylers
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
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
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
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
..
> > }
>
> 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
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
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
[*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
| 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
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
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 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
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
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
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.]
ething more generic.
Nah, the current name is good: it has the convenient mnemonic of being
the name that people "object" to ...
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
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
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
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
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
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 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?
>
>
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
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
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:
> >
. 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
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
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
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
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
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
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 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'.
>
>
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
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
[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_
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
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
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
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
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
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
s a Capture object - see S02
Does the variable name in the comment need changing too?
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
_>, on the grounds that everything always
aliases to C<$_>.
What's the argument for it being C<@_>?
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
1 - 100 of 242 matches
Mail list logo