Re: List assignment question

2006-11-15 Thread Brandon S. Allbery KF8NH
On Nov 15, 2006, at 12:04 PM, Mark J. Reed wrote: On 11/14/06, Vincent Foley [EMAIL PROTECTED] wrote: I was toying around with Pugs and I tried the following Perl 5 list assignment my ($a, undef, $b) = 1..3; Huh. I didn't think that worked in Perl 5, either. What am I

Re: [svn:perl6-synopsis] r13545 - doc/trunk/design/syn

2007-01-29 Thread Brandon S. Allbery KF8NH
On Jan 29, 2007, at 17:06 , [EMAIL PROTECTED] wrote: +absense of context propagation by the optimizer). The value returned Minor spelling nit: absence -- brandon s. allbery[linux,solaris,freebsd,perl] [EMAIL PROTECTED] system administrator [openafs,heimdal,too many hats] [EMAIL

Re: [svn:perl6-synopsis] r13570 - doc/trunk/design/syn

2007-02-05 Thread Brandon S. Allbery KF8NH
On Feb 5, 2007, at 17:26 , [EMAIL PROTECTED] wrote: +This can be viewed as a form of multiple dispatch, except that it's +based on longest-token matching rather than signature matcing. The matcing? -- brandon s. allbery[linux,solaris,freebsd,perl] [EMAIL PROTECTED] system

Re: What should file test operators return?

2007-04-13 Thread Brandon S. Allbery KF8NH
On Apr 12, 2007, at 14:52 , brian d foy wrote: At the moment the file test operators that I expect to return true or false do, but the true is the filename. I expected a boolean, for no other reason than Perl 6 has them so it might as well use them. This is documented somewhere already.

Re: What should file test operators return?

2007-04-13 Thread Brandon S. Allbery KF8NH
On Apr 13, 2007, at 9:04 , brian d foy wrote: In article [EMAIL PROTECTED], Brandon S. Allbery KF8NH [EMAIL PROTECTED] wrote: File tests are supposed to return something which: - behaves as a Bool - stringifies as a filename - numifies as a file size or as a time, if appropriate

Re: File test operators as Pairs

2007-04-13 Thread Brandon S. Allbery KF8NH
On Apr 13, 2007, at 20:09 , Jonathan Lang wrote: What does pair notation buy us that quoted-postfix notation doesn't already cover? I don't think it does. What it does buy is that the *unquoted* notation works: the definition of Perl6's grammar turns out to lead to `-f' and `- f'

Re: [svn:perl6-synopsis] r14382 - doc/trunk/design/syn

2007-04-25 Thread Brandon S. Allbery KF8NH
Minor typo? On Apr 25, 2007, at 1:06 , [EMAIL PROTECTED] wrote: Run-time mixins are done with Cdoes and Cbut. The Cdoes binary operator is a mutator that derives a new anonymous class (if necessary) and binds the object to it: $fido does Sentry -The Cdoes operator is

Re: S12: can(), signatures and casting

2007-04-29 Thread Brandon S. Allbery KF8NH
On Apr 29, 2007, at 6:42 , Jonathan Lang wrote: In effect, the signature gets attached as a property of the string, and 'can()' checks for the signature property. The only problem that I have with this idea is that I can't think of any uses for a signatory string outside of '.can()'. Maybe

Re: propose renaming Hash to Dict

2007-06-01 Thread Brandon S. Allbery KF8NH
On Jun 1, 2007, at 5:44 , Thomas Wittek wrote: Larry Wall: Nope. Hash is mostly about meaning, and very little about implementation. Please don't assume that I name things according to Standard Names in Computer Science. I name things in English. Hash is just something that is

Re: Switch/Given and English, Was perl 6 grammar

2007-12-08 Thread Brandon S. Allbery KF8NH
On Dec 8, 2007, at 9:06 , Richard Hainsworth wrote: or not quite right. And there is absolutely no linguistic link between 'switch' and 'case'. If I am uncomfortable with 'switch', 'case' really sucks. In fact, whenever I work in language other than perl, and 'switch' is the preferred

Re: Definition of Order in S29

2008-01-24 Thread Brandon S. Allbery KF8NH
On Jan 24, 2008, at 23:23 , Darren Duncan wrote: I'd be more interested in hearing what precedents if any exist in this regard. What do other languages call the same concepts? data Ord = LT | EQ | GT -- Haskell -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED]

Re: pluralization idea that keeps bugging me

2008-02-09 Thread Brandon S. Allbery KF8NH
On Feb 9, 2008, at 11:43 , Richard Hainsworth wrote: I posted an idea about pluralisation could be handled in a way that would not be English-centric (Subject: interpolation contextualisation). There were no responses to the idea. Was it so bad? Did no one see it? Was it too un-perlish?

Re: [svn:perl6-synopsis] r14515 - doc/trunk/design/syn

2008-02-23 Thread Brandon S. Allbery KF8NH
Hm, I see a minor nit... On Feb 23, 2008, at 12:40 , [EMAIL PROTECTED] wrote: +A Cproto may share dispatch with multis declared after it in the same scope, -^^ but in that case it functions only as the final tie-breaker if the inner multies can't

Re: muse on Compact Structs, pack/unpack

2008-04-01 Thread Brandon S. Allbery KF8NH
On Apr 1, 2008, at 6:13 , John M. Dlugosz wrote: Meanwhile, how do I use it? my Buf $temp = $record; $stream.print ($temp); $stream.print (Buf $record); $stream.print($record.pack) # I would think? -- brandon s. allbery

Re: muse on Compact Structs, pack/unpack

2008-04-01 Thread Brandon S. Allbery KF8NH
On Apr 1, 2008, at 13:25 , John M. Dlugosz wrote: Brandon S. Allbery KF8NH allbery-at-ece.cmu.edu |Perl 6| wrote: $stream.print (Buf $record); $stream.print($record.pack) # I would think? A .pack member function on a Compact struct is indeed my first gut feeling, but at the end

Re: Easy question: what is a list comprehension ?

2008-04-05 Thread Brandon S. Allbery KF8NH
On Apr 5, 2008, at 15:07 , John M. Dlugosz wrote: What is a list comprehension? I've seen that term bantered around here. The term comes from Haskell and Python; it's a shorthand notation for list generation and filtering. [x | x - some expression involving y, y = some range

Re: postfix and postcircumfix

2008-04-06 Thread Brandon S. Allbery KF8NH
On Apr 6, 2008, at 12:07 , John M. Dlugosz wrote: Larry Wall larry-at-wall.org |Perl 6| wrote: and think you've gotten anywhere, since you'd then have to rewrite it again: $foo.postcircumfix:( ).postcircumfix:( ).($bar) $foo.postcircumfix:( ).postcircumfix:( ).postcircumfix:( )

Re: Nomenclature Question - BEGIN etc.

2008-04-10 Thread Brandon S. Allbery KF8NH
On Apr 10, 2008, at 13:29 , John M. Dlugosz wrote: I might have misremembered, but i thought labels were followed by a colon in Perl 6. A quick scan of the docs... It is illegal for a provisional subroutine call to be followed by a colon postfix, since such a colon is allowed only on an

Re: Nomenclature Question - BEGIN etc.

2008-04-10 Thread Brandon S. Allbery KF8NH
On Apr 10, 2008, at 18:58 , Bob Rogers wrote: From: Larry Wall [EMAIL PROTECTED] Date: Thu, 10 Apr 2008 14:00:53 -0700 On Thu, Apr 10, 2008 at 03:41:19PM -0500, John M. Dlugosz wrote: Well, lessee. The Common Lisp spec calls them situations in the definition of (eval-when)...

Re: Q on function returning

2008-04-13 Thread Brandon S. Allbery KF8NH
On Apr 13, 2008, at 1:20 , John M. Dlugosz wrote: So, what is the role of the inner and outer return types that are declared on the function? While some details have changed since then, you might want to review this thread:

Re: 'returns' vs 'of'

2008-04-13 Thread Brandon S. Allbery KF8NH
On Apr 13, 2008, at 1:28 , John M. Dlugosz wrote: I don't like the assignments of 'returns' and 'of'. I think it is easily confused. I've written foo (Int $x) returns Int I think the main problem here is that of is there only for completeness; one would normally say our Int sub foo

Re: Idea: infir types of constants

2008-04-13 Thread Brandon S. Allbery KF8NH
On Apr 13, 2008, at 2:02 , John M. Dlugosz wrote: In Perl 6, I think you would have to arrange to write the return type later rather than sooner to do this: sub foo (::T $a, T $b) is of T and writing it the other way around would violate the one-pass parsing. Just from looking at

Re: Chained Comparisons ?

2008-04-16 Thread Brandon S. Allbery KF8NH
On Apr 16, 2008, at 3:49 , John M. Dlugosz wrote: Or, are the operators written in a tricky way, to return an object that encapsulates the original right argument and the proper boolean result, and has forms to take this object as well? IOW, no built-in support. Yes, they use

Re: static types, checking, conversions

2008-04-16 Thread Brandon S. Allbery KF8NH
On Apr 16, 2008, at 3:44 , TSa wrote: I found two dissertations and a couple of papers about typing JavaScript. The quintessential is that optional typing is defined as having *no* impact on the dynamic behavior of the program. In that respect type annotations are like comments. I doubt that

Re: Context and return types question

2008-04-21 Thread Brandon S. Allbery KF8NH
On Apr 21, 2008, at 9:39 , John M. Dlugosz wrote: TSa Thomas.Sandlass-at-barco.com |Perl 6| wrote: I think the type is just :( $: :named$ ) if you want to extract the invocant with a $ prefix. Otherwise it would be :( $, :named $ ) and you extract the item positionally with prefix @ or

Re: treatment of isa and inheritance

2008-04-30 Thread Brandon S. Allbery KF8NH
On Apr 30, 2008, at 8:43 AM, TSa wrote: John M. Dlugosz wrote: isa as a synonym for is that turns on warnings is documented at the end of my paper under Concepts discussed in this paper that are not on the Synopses. I totally agree! Using 'isa' pulls in the type checker. Do we have the

Re: treatment of isa and inheritance

2008-04-30 Thread Brandon S. Allbery KF8NH
On Apr 30, 2008, at 15:14 , Jon Lang wrote: Brandon S. Allbery KF8NH wrote: It occurs to me that this shouldn't be new keywords, but adverbs, i.e. ``is :strict Dog''. On a side note, I'd like to make a request of the Perl 6 community with regard to coding style: could we please have

Re: treatment of isa and inheritance

2008-04-30 Thread Brandon S. Allbery KF8NH
On Apr 30, 2008, at 15:14 , Jon Lang wrote: only is is :strictly Dog more legible, but it leaves room for the possible future inclusion of adjective-based syntax such as big Dog It occurs to me that we already have this: we call them types. -- brandon s. allbery

Re: First look: Advanced Polymorphism whitepaper

2008-04-30 Thread Brandon S. Allbery KF8NH
On May 1, 2008, at 0:53 , chromatic wrote: correctness sense. Sadly, both trees and dogs bark.) Hm, no. One's a noun, the other's a verb. Given the linguistic orientation of Perl6, it seems a bit strange that the syntax for both is the same: while accessors and mutators are

Re: First look: Advanced Polymorphism whitepaper

2008-04-30 Thread Brandon S. Allbery KF8NH
On May 1, 2008, at 1:30 , Jon Lang wrote: On Wed, Apr 30, 2008 at 9:58 PM, Brandon S. Allbery KF8NH [EMAIL PROTECTED] wrote: On May 1, 2008, at 0:53 , chromatic wrote: correctness sense. Sadly, both trees and dogs bark.) Hm, no. One's a noun, the other's a verb. Given

Re: First look: Advanced Polymorphism whitepaper

2008-04-30 Thread Brandon S. Allbery KF8NH
On May 1, 2008, at 1:46 , Larry Wall wrote: On Thu, May 01, 2008 at 01:34:45AM -0400, Brandon S. Allbery KF8NH wrote: On May 1, 2008, at 1:30 , Jon Lang wrote: In defense of chromatic's point, both people and syrup run. But there *is* some commonality there, to the extent that both

Re: treatment of isa and inheritance

2008-05-02 Thread Brandon S. Allbery KF8NH
On 2008 May 2, at 5:50, TSa wrote: Brandon S. Allbery KF8NH wrote: It occurs to me that this shouldn't be new keywords, but adverbs, i.e. ``is :strict Dog''. Great idea! But aren't named args required to be after required ones? I was guessing, I still haven't had a chance to mindmeld

Re: All classes imply the existence of a role of the same name.

2008-05-03 Thread Brandon S. Allbery KF8NH
On 2008 May 3, at 6:25, Richard Hainsworth wrote: - if u want to add a role to an existing object, perl wraps the object into a class, adds the role, reinstantiates the object. As I understand it, Perl inserts a new anonymous class as the object's parent, and adds the role to that. The

Re: my TypeName $x;

2008-05-06 Thread Brandon S. Allbery KF8NH
On 2008 May 6, at 10:15, Jon Lang wrote: Signature? If so, what kind of object does the Signature object return if I ask it to give me its invocant? Surely not another Signature object? Whatever it is that Perl 6 returns in that case Turtle? :) -- brandon s. allbery

Re: Minimal Distance (Re: Where is Manhattan Dispatch discussion?)

2008-05-07 Thread Brandon S. Allbery KF8NH
On 2008 May 7, at 4:21, TSa wrote: BTW, what is a flack? He's using flak (shrapnel; usual usage catching flak over ...) without understanding it. Coming back to how C++ handles static overloading. How is the sort order of (int *), (int ), (int), (const int *), (const int ), (const int),

Re: parameters: ref vs rw

2008-05-10 Thread Brandon S. Allbery KF8NH
On 2008 May 10, at 21:46, John M. Dlugosz wrote: In S06, what is the difference between is ref and is rw? The text says that the rw may be converted to an lvalue, and that ref must already be. But what is that supposed to mean? At a guess, is rw makes a parameter variable into a local

Re: Compile-time checking of assignment to read-only variables (Re:MMD distances)

2008-05-15 Thread Brandon S. Allbery KF8NH
On 2008 May 15, at 1:30, Me Here wrote: John M. Dlugosz wrote: no strong_type_check :rw in scope can turn that off, in case you want to play dirty tricks. What is the point of be able to mark things readonly if the compiler does reject assignment attempts? (assuming you meant doesn't)

Re: Compile-time checking of assignment to read-only variables (Re:MMD distances)

2008-05-17 Thread Brandon S. Allbery KF8NH
On 2008 May 17, at 4:10, Carl Mäsak wrote: Whether we're risking the loss of important compiler optimizations by allowing overriding of variable RO-ness is not for me to say, that's up to the compiler writers around here. It seems to me you make it sound worse than it really is, that

Re: assignable mutators (S06/Lvalue subroutines)

2008-05-26 Thread Brandon S. Allbery KF8NH
On 2008 May 26, at 10:19, TSa wrote: John M. Dlugosz wrote: I have similar thoughts. I'm thinking that some macros will aid in writing proper setters via a tie-like mechanism that don't require any core language changes, so it's not a real problem. That is, a reusable proxy class that

Re: The Inf type

2008-06-03 Thread Brandon S. Allbery KF8NH
On 2008 Jun 3, at 3:15, John M. Dlugosz wrote: Jon Lang dataweaver-at-gmail.com |Perl 6| wrote: type (i.e., 'num'). Somehow, I had got it into my head that Num was a role that is done by all types that represent values on the real number line, be they integers, floating-point, rationals,

Re: The Inf type

2008-06-03 Thread Brandon S. Allbery KF8NH
On 2008 Jun 3, at 4:19, John M. Dlugosz wrote: Jon Lang dataweaver-at-gmail.com |Perl 6| wrote: e g. Learn from the Haskell folks, who are still trying to untangle the mess they made of their numeric hierarchy (see http://haskell.org/haskellwiki/Mathematical_prelude_discussion). I'll

Re: [svn:perl6-synopsis] r14563 - doc/trunk/design/syn

2008-07-16 Thread Brandon S. Allbery KF8NH
Minor typo: On 2008 Jul 16, at 15:56, [EMAIL PROTECTED] wrote: +(again, conceptually at the entry to the outer lexical scope, but +possible deferred.) sub foo { possibly -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED] system administrator

Re: Complex planes

2008-07-16 Thread Brandon S. Allbery KF8NH
On 2008 Jul 16, at 18:48, Jon Lang wrote: Moritz Lenz wrote: Principle of least surprise: Suppose sqrt(1) returns any(1, -1): if sqrt($x) 0.5 { do something } I can see the big, fat WTF written in the face of programmer who tries to debug that code, and doesn't know about junctions. It

Re: Code-only forms?

2008-08-02 Thread Brandon S. Allbery KF8NH
On 2008 Aug 2, at 12:57, Larry Wall wrote: On Thu, Jul 31, 2008 at 05:56:14AM -0500, John M. Dlugosz wrote: In S04, Other similar Code-only forms ... What does that mean? It is feebly attempting to say that, because these are control flow functions, the argument is really a thunk that the

Re: [svn:perl6-synopsis] r14573 - doc/trunk/design/syn

2008-08-08 Thread Brandon S. Allbery KF8NH
On 2008 Aug 8, at 10:59, [EMAIL PROTECTED] wrote: Modified: doc/trunk/design/syn/S06.pod = = = = = = = = == --- doc/trunk/design/syn/S06.pod(original) +++ doc/trunk/design/syn/S06.podFri Aug 8 07:59:12 2008 @@

Re: Quick question: (...) vs [...]

2008-08-08 Thread Brandon S. Allbery KF8NH
On 2008 Aug 8, at 22:53, John M. Dlugosz wrote: What is the difference between (1,2,3) and [1,2,3] ? IIRC one is a list, the other a reference to a list --- which in perl6 will be hidden for the most part. so practically speaking the difference is minimal. -- brandon s. allbery

Re: List of captures, why?

2008-08-09 Thread Brandon S. Allbery KF8NH
On 2008 Aug 8, at 23:12, John M. Dlugosz wrote: Brandon S. Allbery KF8NH allbery-at-ece.cmu.edu |Perl 6| wrote: On 2008 Aug 8, at 23:06, John M. Dlugosz wrote: Why is 3;3;3 a list of captures rather than a list of lists? IIRC it has to do with providing enough information for slices

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Brandon S. Allbery KF8NH
On 2008 Aug 12, at 20:39, Austin Hastings wrote: Actually, I proposed some years ago allowing separable verbs -- function/method/operator names with spaces in them, that could in fact bracket or intersperse themselves with other parameters. This would be a way of writing if ... elsif ...

Re: how much detail can I get from caller.want?

2008-09-01 Thread Brandon S. Allbery KF8NH
On 2008 Sep 1, at 15:20, Larry Wall wrote: On Mon, Sep 01, 2008 at 05:52:28PM +0200, TSa wrote: John M. Dlugosz wrote: Perhaps the supplier of the CPAN module for the nth function could also include, besides the actual function, an optimization pattern plug-in that locates the idiom in the

Re: adverbial form of Pairs notation question

2008-09-06 Thread Brandon S. Allbery KF8NH
On 2008 Sep 6, at 13:57, Larry Wall wrote: But basically I think NIL is a mild form of failure anyway, so it's fine with me if () is a form of failure that is smart enough to be I'm thinking () is the non-scalar (list, array, capture, maybe hash) version of undef, which acts like a value

Re: Why no is ro? (Re: Subroutine parameter with trait and default.)

2008-09-24 Thread Brandon S. Allbery KF8NH
On 2008 Sep 24, at 17:45, David Green wrote: On 2008-Sep-23, at 5:27 pm, Michael G Schwern wrote: David Green wrote: Happily, brevity often aids clarity. The rest of the time, it should be up to one's editor; any editor worth its salt ought to easily auto-complete ro into readonly. Eeep!

Re: globs and trees in Perl6

2008-10-01 Thread Brandon S. Allbery KF8NH
On 2008 Oct 1, at 22:14, Timothy S. Nelson wrote: Hi all. I've enjoyed(?) reading over the February/March thread entitled Musings on operator overloading. I've brought a few thoughts along; if they're old news, please tell me here to do more reading on it :). The Perl6 way to do this is

Re: globs and trees in Perl6

2008-10-01 Thread Brandon S. Allbery KF8NH
On 2008 Oct 1, at 22:23, Timothy S. Nelson wrote: On Wed, 1 Oct 2008, Brandon S. Allbery KF8NH wrote: On 2008 Oct 1, at 22:14, Timothy S. Nelson wrote: Hi all. I've enjoyed(?) reading over the February/March thread entitled Musings on operator overloading. I've brought a few thoughts

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Brandon S. Allbery KF8NH
On Oct 2, 2008, at 10:36 , Timothy S. Nelson wrote: On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all

Re: File test ops as string methods

2008-11-07 Thread Brandon S. Allbery KF8NH
On 2008 Nov 7, at 17:49, Mark J. Reed wrote: I'm sure this has been hashed out somewhere I wasn't looking, but i would really prefer for pathname ops not to be mixed in to the Str class. Maybe they could be put in a Pathname subclass of Str, with a simple literal syntax or short unary operator

Re: MAIN conflict in S06?

2008-11-14 Thread Brandon S. Allbery KF8NH
On 2008 Nov 14, at 12:14, Larry Wall wrote: On Thu, Nov 13, 2008 at 07:19:31PM -0600, Patrick R. Michaud wrote: : S06:2362 says: : : You can get the current routine name by calling C? ROUTINE.name. : (The outermost routine at a file-scoped compilation unit is always : named CMAIN

Re: S16: chown, chmod

2008-11-22 Thread Brandon S. Allbery KF8NH
On 2008 Nov 21, at 13:20, Larry Wall wrote: On Fri, Nov 21, 2008 at 09:57:30AM -0800, dpuu wrote: : On Nov 21, 9:16 am, [EMAIL PROTECTED] (Larry Wall) wrote: : Please feel free to whack on the spec : The definition of Cchown includes the statement that it's not : available on most system unless

Re: S16: chown, chmod

2008-11-22 Thread Brandon S. Allbery KF8NH
On 2008 Nov 21, at 14:13, Dave Whipp wrote: The restriction of chown to the superuser is a property of the OS, not the files. The example from the pod is: man pathconf -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED] system administrator [openafs,heimdal,too many

Re: S16: chown, chmod

2008-11-23 Thread Brandon S. Allbery KF8NH
On 2008 Nov 23, at 18:35, dpuu wrote: On Nov 23, 2:33 pm, [EMAIL PROTECTED] (Aristotle Pagaltzis) wrote: The API you propose does not seem to me to shorten code at all and is likely to lead to problematic code, so it seems like a bad idea. Interfaces should be designed to encourage people to do

Re: S16: chown, chmod

2008-11-24 Thread Brandon S. Allbery KF8NH
On 2008 Nov 24, at 10:36, dpuu wrote: On Nov 23, 3:56 pm, [EMAIL PROTECTED] (Brandon S. Allbery KF8NH) wrote: I think you're seeing something other than what we are. Checking any external resource before operating on it introduces a race condition which can allow an attacker to swap resources

Re: S16: chown, chmod

2008-11-24 Thread Brandon S. Allbery KF8NH
On 2008 Nov 24, at 10:45, dpuu wrote: PS. From S16, q{ ... On POSIX systems, you can detect this condition this way: use POSIX qw(sysconf _PC_CHOWN_RESTRICTED); $can_chown_giveaway = not sysconf(_PC_CHOWN_RESTRICTED); } From this I inferred that the purpose of this assignment was to do a

Re: Files, Directories, Resources, Operating Systems

2008-12-09 Thread Brandon S. Allbery KF8NH
On 2008 Dec 9, at 19:56, Aristotle Pagaltzis wrote: * Aristotle Pagaltzis [EMAIL PROTECTED] [2008-12-10 01:10]: Well go on. Btw, I just realised that it can be read as sarcastic, which I didn’t intend. I am honestly curious, even if skeptical. I am biased, but I am open to be convinced.

Re: Files, Directories, Resources, Operating Systems

2008-12-09 Thread Brandon S. Allbery KF8NH
On 2008 Dec 9, at 21:11, Charles Bailey wrote: It may well be that a fine-grained interface isn't practical, but perhaps there are some basics that we could implement, such as - set owner of this thing - (maybe) set group of this thing Group is problematic; I don't recall Windows having group

Re: Roles and IO?

2008-12-11 Thread Brandon S. Allbery KF8NH
On 2008 Dec 11, at 20:16, Leon Timmermans wrote: One main problem with filehandles is that are rather diverse. The only operation that all of them have in common is close. Reading versus Be glad Xenix is dead. There were filehandles which didn't even support close() (they were actually

Re: 6PAN idea

2008-12-16 Thread Brandon S. Allbery KF8NH
On 2008 Dec 16, at 23:00, Timothy S. Nelson wrote: One thing I've been working on recently is a (Perl 5) object that models package metadata. In theory, it should be able to model the metadata from a .rpm, a .deb, a CPAN package, or whatever. Then you read the data using a metadata input

Re: Recommended Perl 6 best practices?

2008-12-20 Thread Brandon S. Allbery KF8NH
On 2008 Dec 20, at 13:39, Carl Mäsak wrote: Maybe this counts as a best practice, or maybe it's more of a pattern. In a recent piece of code, I found a way to exploit code blocks to act like return statements with side effects. The resulting code became very clean, so I decided to blog about the

Re: use semantics

2009-01-04 Thread Brandon S. Allbery KF8NH
On 2009 Jan 4, at 8:53, Carl Mäsak wrote: Now, I can precompile the B module to PIR without a problem, but when I compile the A module, Rakudo/Parrot aborts because it runs the code in B and dies. $ parrot languages/perl6/perl6.pbc --target=pir --output=B.pir B.pm $ parrot

Re: r24769 - docs/Perl6/Spec

2009-01-05 Thread Brandon S. Allbery KF8NH
On 2009 Jan 5, at 11:54, pugs-comm...@feather.perl6.nl wrote: + our Str multi method perl (Object $o) + +Returns a perlish representation of the object, so that calling Ceval +on the returned string reproduces the object as good as possible. My inner English teacher cringes in pain. It

Re: [PATCH] Add .trim method

2009-01-13 Thread Brandon S. Allbery KF8NH
On 2009 Jan 12, at 15:17, Ovid wrote: בָּרוּךְ שֵׁם כְּבוֹד מַלְכוּתוֹ לְעוֹלָם וָעֶד. If you can't see that in your client, that's Hebrew from http://www.i18nguy.com/unicode/shma.html and means Hear O Israel, the Lord is our God, the Lord is One. Actually that's the

Re: RFD: Built-in testing

2009-01-23 Thread Brandon S. Allbery KF8NH
On 2009 Jan 21, at 7:35, Carl Mäsak wrote: Moritz (): So Larry and Patrick developed the idea of creating an adverb on the test operator instead: $x == 1e5 :ok('the :ok makes this is a test'); I'm trying to explain to myself why I don't like this idea at all. I'm only partially

Re: r25102 - docs/Perl6/Spec

2009-02-01 Thread Brandon S. Allbery KF8NH
On 2009 Jan 30, at 11:30, Larry Wall wrote: So I'm open to suggestions for what we ought to call that envelope if we don't call it the prelude or the perlude. Locale is bad, environs is bad, context is bad...the wrapper? But we have dynamic wrappers already, so that's bad. Maybe the setting,

Re: r25182 - docs/Perl6/Spec

2009-02-05 Thread Brandon S. Allbery KF8NH
On 2009 Feb 4, at 11:45, Aaron Crane wrote: FWIW, I prefer the traditional spelling, writable. Google suggests that writeable is more common on the web, though; 4.8 versus 3.7 Mghits. I have to admit that writable suggests to me that you can serve a writ on it; an unlikely case for even

Re: r25182 - docs/Perl6/Spec

2009-02-05 Thread Brandon S. Allbery KF8NH
On 2009 Feb 4, at 12:56, Leon Timmermans wrote: On Wed, Feb 4, 2009 at 4:37 PM, pugs-comm...@feather.perl6.nl wrote: +=item method IO dup() Do we really want that? POSIX' dup does something different from what many will expect. In particular, the new file descriptors share the offset, which

Re: r25182 - docs/Perl6/Spec

2009-02-06 Thread Brandon S. Allbery KF8NH
On 2009 Feb 6, at 6:24, Daniel Ruoso wrote: Em Sex, 2009-02-06 às 02:07 -0500, Brandon S. Allbery KF8NH escreveu: I would think fcntl() is just the Unix version of a more general concept, which is probably wider than POSIX. Maybe this wider concepts can be expressed in their own roles

Re: r25328 - docs/Perl6/Spec

2009-02-14 Thread Brandon S. Allbery KF8NH
On 2009 Feb 14, at 12:01, Leon Timmermans wrote an unending refrain of: Why should this do POSIX? What about non-POSIX operating systems? I think the point here is that on POSIX systems that gets you ioctl() and fcntl(), and on non-POSIX systems either they don't exist or they throw

Re: r25328 - docs/Perl6/Spec

2009-02-15 Thread Brandon S. Allbery KF8NH
On 2009 Feb 15, at 22:50, Timothy S. Nelson wrote: On Sat, 14 Feb 2009, Leon Timmermans wrote: +=item sysopen I vote for sysopen (and all other sys functions) to be wiped out of existence. Disagree -- I think these belong in IO::Unbuffered. Maybe we could make that optional, though I

Re: The use of roles in S16 (Was: Re: r25328 - docs/Perl6/Spec)

2009-02-17 Thread Brandon S. Allbery KF8NH
On 2009 Feb 16, at 22:44, Timothy S. Nelson wrote: So you can have a stream handle which does IO::Writeable, but will throw an error on any attempt to write? Anyway, you've answered my question in the other e-mail. Not sure what you're getting at, but the obvious example is a writeable

Re: Exegesis 7/format() question

2009-02-19 Thread Brandon S. Allbery KF8NH
On 2009 Feb 17, at 1:54, Timothy S. Nelson wrote: Hi all. According to S29, the Perl 5 format() function is obsolete, and it says See Exegesis 7. According to Exegesis 7, there will be a Form.pm which implements similar functionality, but has to be used. My questions are: 1. Is

Re: r25445 - docs/Perl6/Spec/S32-setting-library

2009-02-21 Thread Brandon S. Allbery KF8NH
On 2009 Feb 20, at 12:21, Daniel Ruoso wrote: Em Sex, 2009-02-20 às 10:40 -0600, Dave Rolsky escreveu: On Fri, 20 Feb 2009, Daniel Ruoso wrote: If we're going to use an epoch, it should be the Operating System's epoch. Anything else will lead to confusion and disorder ;P And which OS epoch

Re: Perl's internal time (was: Re: r25445 - docs/Perl6/Spec/S32-setting-library)

2009-02-21 Thread Brandon S. Allbery KF8NH
On 2009 Feb 20, at 14:36, Chris Dolan wrote: UTC: TAI with an offset, as corrected for the actual revolution of the Earth: usually 60 seconds in a minute, but occasionally 59 or 61. 60 minutes in every hour (so 3599, 3600, or 3601 seconds), 24 hours in every day (86399, 86400, or 86401

Re: r25490 - docs/Perl6/Spec

2009-02-24 Thread Brandon S. Allbery KF8NH
On 2009 Feb 22, at 22:47, pugs-comm...@feather.perl6.nl wrote: +$?PUGS_VERSION # Pugs version (not canonical) +$*PUGS_HAS_HSPLUGINS # True if Pugs was compiled with support for hsplugins + # (not canonical) These should not be part of the standard. But while

Re: r25490 - docs/Perl6/Spec

2009-02-24 Thread Brandon S. Allbery KF8NH
On 2009 Feb 23, at 22:43, Timothy S. Nelson wrote: On Mon, 23 Feb 2009, jason switzer wrote: On Sun, Feb 22, 2009 at 9:47 PM, pugs-comm...@feather.perl6.nl wrote: +$*PROGRAM_NAME # name of the program being executed How does this differ from $*EXECUTABLE_NAME? Good question.

Re: Temporal changes

2009-02-24 Thread Brandon S. Allbery KF8NH
On 2009 Feb 23, at 8:34, Ruud H.G. van Tol wrote: Martin D Kealey wrote: Ah, we want a noun that isn't readily confused as an adjective. Suitable terms might include: Instant Jiffy Juncture Moment Occasion Snap Tick ... Once :) Then? -- brandon s. allbery

Re: Comparing inexact values (was Re: Temporal changes)

2009-02-26 Thread Brandon S. Allbery KF8NH
On 2009 Feb 26, at 13:00, Jon Lang wrote: I'm not sold on the notion that Num should represent a range of values Arguably a range is the only sane meaning of a floating point number. -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allb...@kf8nh.com system administrator

Re: Comparing inexact values (was Re: Temporal changes)

2009-02-26 Thread Brandon S. Allbery KF8NH
On Feb 26, 2009, at 14:27 , Jon Lang wrote: Jon Lang wrote: Brandon S. Allbery wrote: Jon Lang wrote: I'm not sold on the notion that Num should represent a range of values Arguably a range is the only sane meaning of a floating point number. Perhaps; but a Num is not necessarily a

Re: $?OS change

2009-03-02 Thread Brandon S. Allbery KF8NH
On 2009 Mar 2, at 6:19, Timothy S. Nelson wrote: On Mon, 2 Mar 2009, Chris Dolan wrote: On Mar 2, 2009, at 12:04 AM, Timothy S. Nelson wrote: Hi. I note that we have $?OS, $?VM, and $?DISTRO (and their $* counterparts). I'd like to recommend that we eliminate $?OS, and replace it with

Re: Getting rid of want()

2009-03-31 Thread Brandon S. Allbery KF8NH
On 2009 Mar 31, at 17:04, Moritz Lenz wrote: We had a discussion on #perl6 tonight about how to implement want(), and basically came to no conclusion. Then I came up with the idea that any lazy implementor will come up with: drop it from the language. Hm, I was under the impression that

Re: Unicode in 'NFG' formation ?

2009-05-18 Thread Brandon S. Allbery KF8NH
On May 18, 2009, at 09:21 , Mark J. Reed wrote: If you're doing arithmetic with the code points or scalar values of characters, then the specific numbers would seem to matter. I'm I would argue that if you are working with a grapheme cluster (grapheme), arithmetic on individual grapheme

Re: Unicode in 'NFG' formation ?

2009-05-18 Thread Brandon S. Allbery KF8NH
On May 18, 2009, at 14:16 , Larry Wall wrote: On Mon, May 18, 2009 at 11:11:32AM +0200, Helmut Wollmersdorfer wrote: 3) Details of 'life-time', round-trip. Which is a very interesting topic, with connections to type theory, scope/domain management, and security issues (such as the possibility

Re: Unicode in 'NFG' formation ?

2009-05-18 Thread Brandon S. Allbery KF8NH
On May 18, 2009, at 21:54 , Larry Wall wrote: On Mon, May 18, 2009 at 07:59:31PM -0500, John M. Dlugosz wrote: No, a few million code points in the Unicode standard can produce an arbitrary number of unique grapheme clusters, since you can apply as many modifiers as you like to each different

Re: Illustration of stuff we've been discussing

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 28, 2009, at 10:27 , John M. Dlugosz wrote: Daniel Ruoso daniel-at-ruoso.com |Perl 6| wrote: Em Qui, 2009-05-28 às 00:24 -0500, John M. Dlugosz escreveu: Please see http://www.dlugosz.com/Perl6/web/info-model-1.html and talk to me about it. The illustratino is cool, but it doesn't

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 27, 2009, at 13:59 , Daniel Carrera wrote: Wow... That's a foldl! In a functional language, that would be called a fold. It's very popular in Haskell. I like that Perl 6 seems to be taking steps in the direction of functional languages. First lazy lists (0..Inf) and now a fold. :-D

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 27, 2009, at 15:42 , Daniel Carrera wrote: Mark J. Reed wrote: Note that of the examples given, only Perl 6 and Common Lisp do two things that help immensely simplify the result: 1. reference the built-in * operator directly, without having to wrap it in a lambda expression; 2.

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 27, 2009, at 18:05 , John M. Dlugosz wrote: And APL calls it |¨ (two little dots high up) buh? Metaoperator / (+/LIST). -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allb...@kf8nh.com system administrator [openafs,heimdal,too many hats] allb...@ece.cmu.edu electrical and

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 28, 2009, at 06:43 , Jon Lang wrote: What I'm wondering is how the list knows to feed two items into '[+]'. While 'infix:+' must accept exactly two arguments, '[+]' can accept an arbitrarily long (or short) list of arguments. I thought that at first too, then remembered a discussion

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 29, 2009, at 15:43 , John M. Dlugosz wrote: Care to try ☃ ? That's alt-meta-hyper-doublebucky-cokebottle. *puzzled as to why OSX Character Map thinks that's related to 雪* -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allb...@kf8nh.com system administrator

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 29, 2009, at 21:50 , Timothy S. Nelson wrote: some Linux programs support it too. Unfortunately my e-mail program (Pine) seems to have some trouble with unicode -- I may have to look at alternatives after 14 years of use :(. http://www.washington.edu/alpine/ -- brandon s. allbery

Re: Amazing Perl 6

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 29, 2009, at 22:40 , Timothy S. Nelson wrote: On Fri, 29 May 2009, John M. Dlugosz wrote: Ah yes, on the PC historically you hold down the ALT key and type the code with the numpad keys. At least when I used it, this was a decimal, rather than hex number, and had to be preceded by

Re: renaming or adding some operators

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 29, 2009, at 22:33 , Jon Lang wrote: also is an ordered, short-circuiting version of (and thus all). For some time now, I've wanted an analog for '|' and 'any' - but the only name I can think of for it would be 'else', which has some obvious clarity issues. I have seen x (alt. y) used

Re: renaming or adding some operators

2009-05-31 Thread Brandon S. Allbery KF8NH
On May 30, 2009, at 15:38 , Larry Wall wrote: Perhaps something like use *; should pull in all the Unicode operators. Which if course means that any golfing would start with *; ⨷ perhaps? It only makes sense that a Unicode operator be used to pull in all of Unicode. -- brandon

  1   2   >