Day 21: Your questions wanted!

autrijus on 2005-02-21T19:23:49

Most of my time today has been spent on writing Apocrypha 1, "Overview of the Pugs project". As I plan to write it as Catechism (i.e. Q&A format), I solicited #perl6 for questions. Here is a list of unsorted questions I compiled:

  • What is Pugs?
  • Where can I download Pugs?
  • Why isn't Pugs called Perl6?
  • Is Perl6 fully specified now?
  • Is Pugs's goal to be a fully fledged perl6 compiler or interpreter?
  • Does Pugs run on every platform perl runs on?
  • Who owns Pugs?
  • When will Pugs be finished?
  • Is Pugs compiled or interpreted?
  • Will Autrijus teach haskell for other perl6 developers?
  • I want to learn Perl6. What texts should I read?
  • I want to learn Haskell. What texts should I read?
  • Is Haskell portable?
  • Why do you use both darcs and svk?
  • Is Pugs a perl foundation project?
  • Will Pugs die when the official perl6 is done?
  • Will Autrijus unexpectly abandon the project?
  • Is there a Cabal?
  • How can I help?
  • Will you accept my patch?
  • Do I have to know Haskell to hack Pugs?
  • Will Pugs always be in haskell?
  • Where can i learn haskell?
  • How does Pugs relate to parrot ?
  • Aren't Haskell and Perl incompatible by nature?
  • Can Pugs run parrot code?
  • Will CPAN work on Pugs?
  • Can Pugs run perl5 code?
  • What does the Pugs name come from?
  • Are there other real programs out there written in haskell ?
  • What's featherweight Perl6?
  • Why did Autrijus go beyond larry's back to create Pugs?
  • What's the goal of Pugs?
  • Why not just use Ruby? it's perl6 now.
  • Is Pugs a *schism* in the Perl community?
  • Since you did it in 3 weeks, now we don't need to pay the perl foundation half a million dollars to create perl6, right?
  • Will you implement a DynaLoader equivalent for Pugs?
  • does Pugs run under .Net and Java?
  • Can Pugs run all the code in Apocalypse, Exgesis and Synopses?
  • Does lwall approve of Pugs?
  • This all sounds very exciting. what drugs are you on ?
  • Will Pugs compile and interpret haskell code to run in parrot vm?
  • Perl5 is bloated, untyped, fragile, slow and obfuscated; why should I spend time in hacking Perl6?
  • The parrot/perl6 program hasn't made perl6 happen in 5 years. What makes you think you can do it?
  • Perl5 is wonderful. Why should I care about perl6?
  • If I have a .pl6 file, will Pugs run it?
  • Can I write CGI code with Pugs?
  • Is there a mod_pugs?
  • I replaced /usr/bin/perl with Pugs, but now my perl5 programs don't run. why not?
  • Where do i report bugs in Pugs to?
  • I filed a bug against Pugs via perlbug, but they said i had to report it somewhere else. where is that?
  • I have written some Pugs modules. Where should I upload it?
  • Why doesn't Pugs ship with CPAN or CPANPLUS?
  • Is there an Inline::Perl6 or Inline::Pugs?
  • Is Pugs free software?
  • If I use Pugs, do i have to share my source code with everyone?
  • Is Pugs licensed under the same terms as perl itself?
  • What is your worst/best (haskell) hack in Pugs?
  • What is a "golfing system"?
  • Who is Autrijus anyway?
  • How many people are actually behind the autrijus pseudonym?
  • Were animals harmed during the making of Pugs?
  • Is there a RSS feed for Pugs news?
  • What's with those Tolkien poetry in Pugs source code files?
  • Is there a commitlog email list for Pugs?
  • What is a monad, and what's in the Eval monad?
  • If I enter ICFP 2005 with Perl6 and Pugs, what is my chance of winning?

I need more questions of all sorts, so you can help. Please leave a comment here that contain any number of questions that you'd like to see answered. Thanks! :-)

...now, to the journal itself...

Today #perl6 is busy resolving edge cases and inconsistencies in the typing system. I'm truly happy that my two outstanding question on p6l (IType vs VType and Context paradox in multisub dispatching) has met with suitable solutions.

Of particular importance is that, with help from luqui (Luke Palmer), pmichaud (Patrick Michaud) and lathos (Simon Cozens), we have got the to bottom of the "punning" problem of ambiguous of "Array" as a implementation type, and "Array" as a value type. The solution in Pugs is simply to excise all implementation types, except for "Variable" and "Constant". We will see more of implementation types when we get to the Tieable class.

Also of note is that the Parser will begin to do typechecking and inferencing, and ill-typed multisub dispatches will be caught at compile time, instead of delaying until runtime paradox appears.

On the code front, hcchien and juerd continue adding new tests and removing TODO tags from tests that now works, while ycheng implemented unlink(). I've implemented defined() and undef() (both nullary and unary variants) at Juerd's request, and ref() at Steve_p's.

Oh! And I'm happy that http://dev.perl.org/perl6 links to http://pugscode.org now. Wonderful. :)


pugs (ghc actually) build error under cygwin

jeff on 2005-02-22T09:01:56

sorry if this isn't the best place to put this. i'm having trouble getting to #perl6 due to '*** No identd (auth) response'. (i am an irc newbie, and am trying to connect using 'irc' at cygwin bash command line under windows xp sp2 using 'irc -c perl6 jefft irc.freenode.net')

fwiw, i also tried to post this to perl.perl6.compiler but google complained of 'temporary error' and i lost the post. not my day ;) (now i seem to recall there may have discussion about problems with this group on google ... hrmph)

faq suggestion: is there a place on the web to read archived #perl6 ?

getting back to my story, i want to build pugs.

first i downloaded a ghc binary for windows (this is ghc-ming32, a cygwin binary is not supported due to purported maintainence issues with cygwin1.dll -- see 'Building the Glasgow Functional Programming Tools Suite')

i then attempted to build pugs but got a problem with linking a posix library:

ghc --make -o pugs src/Main.hs -isrc -v ...
src/Posix.hs:
        Can't find module `System.Posix.Unistd'
        locations searched:
                System/Posix/Unistd.hs
                System/Posix/Unistd.lhs
                src/System/Posix/Unistd.hs
                src/System/Posix/Unistd.lhs
                c:/ghc/ghc-6.2.2/imports/System/Posix/Unistd.hi

(i had checked out the latest svn repository and followed the README instructions first, before adding the -v)

then i chatted on #perl6 for a bit (not sure how i managed to connect earlier... can't seem to now) and was advised that i needed a ghc built under cygwin in order to pick up the required posix library....

fortunately, the earlier ghc download would not be wasted as i would need a running version of ghc to build ghc.

so i downloaded the source blob for stable 6.2.2 and got surprisingly far: ./configure --prefix=/usr/local/ghc
make ...
()
ghc.exe: unknown package name: unix
make[2]: *** [depend] Error 1
make[1]: *** [boot] Error 1
make[1]: Leaving directory `/home/jeff/ghc-source/ghc-6.2.2/ghc'
make: *** [build] Error 1

without musing over the broken bit pile for too long, it seems like i may have chicken and egged myself into a corner.

maybe to build a ghc-cygwin in order to pick up the posix library, i can not bootstrap from the windows ghc-ming32 binary at haskell.org/ghc because it doesn't have a package called 'unix' (makes sense that it might not i guess)

does pugs really require posix already? (maybe so due to a library dependancy perhaps...) i could avoid this whole problem if it didn't.

is there a simple way i can extend my ghc-ming32 prelude with 'unix' package ? or something similar, somehow? ...in order to bootstrap past this problem?

i'm afraid i could use some help as i'm an utter newbie to haskell.

someday i'll buy a newer laptop and convert the old one to linux and have more options... but for now i've got too much blood invested in my cygwin tools and not enough disk space to dual boot...

jeff

Re:pugs (ghc actually) build error under cygwin

jeff on 2005-02-22T09:11:41

to be a bit more clear, the error of not finding 'package unix' happened after alot of apparently succesful building took place. and it happened on a huge ghc call, i presume it is a linking step.

here is the huge command line that caused the error, for whatever it may be worth :

/usr/local/bin/ghc -M -optdep-f -optdep.depend-BASE -osuf o -I../includes -H16m -O -iutils -ibasicTypes -itypes -ihsSyn -iprelude -irename -itypecheck -ideSu gar -icoreSyn -ispecialise -isimplCore -istranal -istgSyn -isimplStg -icodeGen -iabsCSyn -imain -iprofiling -iparser -icprAnalysis -icompMan -indpFlatten -icbit s -inativeGen -ighci -DGHCI -package haskell-src -package unix -cpp -fglasgow-exts -Rghc-timing -I. -IcodeGen -InativeGen -Iparser -recomp -Rghc-timing -H16M '- #include "hschooks.h"' absCSyn/AbsCSyn.lhs absCSyn/AbsCUtils.lhs absCSyn/CLabel.lhs absCSyn/CStrings.lhs absCSyn/Costs.lhs absCSyn/MachOp.hs absCSyn/PprAbsC.lhs basicTypes/BasicTypes.lhs basicTypes/DataCon.lhs basicTypes/Demand.lhs basicTypes/FieldLabel.lhs basicTypes/Id.lhs basicTypes/IdInfo.lhs basicTypes/Literal.lhs basicTypes/MkId.lhs basicTypes/Module.lhs basicTypes/Name.lhs basicTypes/NameEnv.lhs basicTypes/NameSet.lhs basicTypes/NewDemand.lhs basicTypes/OccName.lhs bas icTypes/RdrName.lhs basicTypes/SrcLoc.lhs basicTypes/UniqSupply.lhs basicTypes/Unique.lhs basicTypes/Var.lhs basicTypes/VarEnv.lhs basicTypes/VarSet.lhs codeGen /Bitmap.hs codeGen/CgBindery.lhs codeGen/CgCase.lhs codeGen/CgClosure.lhs codeGen/CgCon.lhs codeGen/CgConTbls.lhs codeGen/CgExpr.lhs codeGen/CgHeapery.lhs codeG en/CgLetNoEscape.lhs codeGen/CgMonad.lhs codeGen/CgRetConv.lhs codeGen/CgStackery.lhs codeGen/CgTailCall.lhs codeGen/CgUpdate.lhs codeGen/CgUsages.lhs codeGen/C losureInfo.lhs codeGen/CodeGen.lhs codeGen/SMRep.lhs compMan/CompManager.lhs coreSyn/CoreFVs.lhs coreSyn/CoreLint.lhs coreSyn/CorePrep.lhs coreSyn/CoreSyn.lhs c oreSyn/CoreTidy.lhs coreSyn/CoreUnfold.lhs coreSyn/CoreUtils.lhs coreSyn/ExternalCore.lhs coreSyn/MkExternalCore.lhs coreSyn/PprCore.lhs coreSyn/PprExternalCore .lhs coreSyn/Subst.lhs cprAnalysis/CprAnalyse.lhs deSugar/Check.lhs deSugar/Desugar.lhs deSugar/DsArrows.lhs deSugar/DsBinds.lhs deSugar/DsCCall.lhs deSugar/DsE xpr.lhs deSugar/DsForeign.lhs deSugar/DsGRHSs.lhs deSugar/DsListComp.lhs deSugar/DsMeta.hs deSugar/DsMonad.lhs deSugar/DsUtils.lhs deSugar/Match.lhs deSugar/Mat chCon.lhs deSugar/MatchLit.lhs ghci/ByteCodeAsm.lhs ghci/ByteCodeFFI.lhs ghci/ByteCodeGen.lhs ghci/ByteCodeInstr.lhs ghci/ByteCodeItbls.lhs ghci/ByteCodeLink.lh s ghci/InteractiveUI.hs ghci/Linker.lhs ghci/ObjLink.lhs hsSyn/Convert.lhs hsSyn/HsBinds.lhs hsSyn/HsCore.lhs hsSyn/HsDecls.lhs hsSyn/HsExpr.lhs hsSyn/HsImpExp. lhs hsSyn/HsLit.lhs hsSyn/HsPat.lhs hsSyn/HsSyn.lhs hsSyn/HsTypes.lhs main/BinIface.hs main/CmdLineOpts.lhs main/CodeOutput.lhs main/Config.hs main/Constants.lh s main/DriverFlags.hs main/DriverMkDepend.hs main/DriverPhases.hs main/DriverPipeline.hs main/DriverState.hs main/DriverUtil.hs main/ErrUtils.lhs main/Finder.lh s main/GetImports.hs main/HscMain.lhs main/HscStats.lhs main/HscTypes.lhs main/Interpreter.hs main/Main.hs main/MkIface.lhs main/Packages.lhs main/ParsePkgConf. hs main/SysTools.lhs main/TidyPgm.lhs nativeGen/AbsCStixGen.lhs nativeGen/AsmCodeGen.lhs nativeGen/AsmRegAlloc.lhs nativeGen/MachCode.lhs nativeGen/MachMisc.lhs nativeGen/MachRegs.lhs nativeGen/PprMach.lhs nativeGen/RegAllocInfo.lhs nativeGen/Stix.lhs nativeGen/StixMacro.lhs nativeGen/StixPrim.lhs ndpFlatten/FlattenInf o.hs ndpFlatten/FlattenMonad.hs ndpFlatten/Flattening.hs ndpFlatten/NDPCoreUtils.hs ndpFlatten/PArrAnal.hs parser/Ctype.lhs parser/LexCore.hs parser/Lexer.hs pa rser/Parser.hs parser/ParserCore.hs parser/ParserCoreUtils.hs parser/RdrHsSyn.lhs prelude/ForeignCall.lhs prelude/PrelInfo.lhs prelude/PrelNames.lhs prelude/Pre lRules.lhs prelude/PrimOp.lhs prelude/PrimRep.lhs prelude/TysPrim.lhs prelude/TysWiredIn.lhs profiling/CostCentre.lhs profiling/SCCfinal.lhs rename/RnBinds.lhs rename/RnEnv.lhs rename/RnExpr.lhs rename/RnHiFiles.lhs rename/RnHsSyn.lhs rename/RnIfaces.lhs rename/RnNames.lhs rename/RnSource.lhs rename/RnTypes.lhs simplCo re/CSE.lhs simplCore/FloatIn.lhs simplCore/FloatOut.lhs simplCore/LiberateCase.lhs simplCore/OccurAnal.lhs simplCore/SAT.lhs simplCore/SATMonad.lhs simplCore/Se tLevels.lhs simplCore/SimplCore.lhs simplCore/SimplMonad.lhs simplCore/SimplUtils.lhs simplCore/Simplify.lhs simplStg/SRT.lhs simplStg/SimplStg.lhs simplStg/Stg Stats.lhs specialise/Rules.lhs specialise/SpecConstr.lhs specialise/Specialise.lhs stgSyn/CoreToStg.lhs stgSyn/StgLint.lhs stgSyn/StgSyn.lhs stranal/DmdAnal.lhs stranal/SaAbsInt.lhs stranal/SaLib.lhs stranal/StrictAnal.lhs stranal/WorkWrap.lhs stranal/WwLib.lhs typecheck/Inst.lhs typecheck/TcArrows.lhs typecheck/TcBind s.lhs typecheck/TcClassDcl.lhs typecheck/TcDefaults.lhs typecheck/TcDeriv.lhs typecheck/TcEnv.lhs typecheck/TcExpr.lhs typecheck/TcForeign.lhs typecheck/TcGenDe riv.lhs typecheck/TcHsSyn.lhs typecheck/TcIfaceSig.lhs typecheck/TcInstDcls.lhs typecheck/TcMType.lhs typecheck/TcMatches.lhs typecheck/TcMonoType.lhs typecheck /TcPat.lhs typecheck/TcRnDriver.lhs typecheck/TcRnMonad.lhs typecheck/TcRnTypes.lhs typecheck/TcRules.lhs typecheck/TcSimplify.lhs typecheck/TcSplice.lhs typech eck/TcTyClsDecls.lhs typecheck/TcTyDecls.lhs typecheck/TcType.lhs typecheck/TcUnify.lhs types/Class.lhs types/FunDeps.lhs types/Generics.lhs types/InstEnv.lhs t ypes/PprType.lhs types/TyCon.lhs types/Type.lhs types/TypeRep.lhs types/Variance.lhs utils/Bag.lhs utils/Binary.hs utils/BitSet.lhs utils/Digraph.lhs utils/Fast MutInt.lhs utils/FastString.lhs utils/FastTypes.lhs utils/FiniteMap.lhs utils/ListSetOps.lhs utils/Maybes.lhs utils/OrdList.lhs utils/Outputable.lhs utils/Panic .lhs utils/Pretty.lhs utils/PrimPacked.lhs utils/StringBuffer.lhs utils/UnicodeUtil.lhs utils/UniqFM.lhs utils/UniqSet.lhs utils/Util.lhs

ghc.exe: unknown package name: unix
make[2]: *** [depend] Error 1
make[1]: *** [boot] Error 1
make[1]: Leaving directory `/home/jeff/ghc-source/ghc-6.2.2/ghc'
make: *** [build] Error 1

Re:pugs (ghc actually) build error under cygwin

autrijus on 2005-02-22T10:14:30

  1. Do not build GHC from the source. Use the binary. :)
  2. Do not run ghc by yourself; use "perl Makefile.PL ; nmake" instead, as detailed in README.

Thanks,
/Autrijus/

Re:pugs (ghc actually) build error under cygwin

jeff on 2005-02-23T06:09:42

ahhh, the light clicks on.... don't use cygwin !

i wasn't familiar with 'nmake' and so had glossed over the larger meaning of the comment...

from a quick google of nmake it appears it is distributed with devstudio... unfortunately i don't microsoft development tools installed.

does anyone know if this is freely available or if there is a freely available substitute or alternative ?

(i'll dig in deeper to this soon -- thanks for the clarification... )

Re:pugs (ghc actually) build error under cygwin

jeff on 2005-02-23T06:26:45

ok, it seems a free nmake is available for download from this microsoft support article :

http://support.microsoft.com/default.aspx?scid=kb;en-us;Q132084

perhaps that info could land in the FAQ ? (assuming its the best way to grab nmake...)

Re:pugs (ghc actually) build error under cygwin

autrijus on 2005-02-24T03:03:03

"perl Makefile.PL" downloads nmake.exe for you. :)

Re:pugs (ghc actually) build error under cygwin

jeff on 2005-02-24T07:15:54

thanks for the nugget!

i'm laughing as i write this. i think i need to leap before i look in this case (before thinking about leaping before looking...)

jeff

Re:pugs (ghc actually) build error under cygwin

nicholas on 2005-02-22T11:26:57

perl.perl6.compiler but google complained of 'temporary error' and i lost the post.

Don't post to google groups. The perl "groups" there are only mirrors of the lists, the lists don't accept incoming posts from google, and so anything posted there is effectively lost. Just send mail to perl6-compiler@perl.org, it will get moderator approval and soon be on the list.

The information about not posting to google groups is repeated fairly regularly on the Perl 6 list summary - I'm not sure how else it can be made more prominient, as it seems that google have no reason to provide a means to disable posting on a per group basis.

Re:pugs (ghc actually) build error under cygwin

jeff on 2005-02-24T07:25:19

thanks for this info. the back of my brain did vaguely itch that i had read something of this somewhere before as i attempted the google post...

in terms of 'how else it can be made more prominent'... i suggest a FAQ as a good start.

perhaps the PUGS faq would host such info to start with (in addition to such good info as what good drugs is Autrijus on anyways?)...

additional helpful info might be recommended tools to properly format the mail being sent to the list... for instance, can outlook express handle this with its Newsgroups features ?

maybe all this exists and i just need another whack with the clue stick...

anyone else want to jump in and help an irc newbie with ident problems ? :)

thanks for your help,
jeff