Parrot 3.5.0 "Menelaus" released | parrot.org | Log: irclog.perlgeek.de/parrot/today
Set by moderator on 21 June 2011.
whiteknight hello dukeleto 00:00
00:05 mtk left, cjh left
dukeleto whiteknight: howdy. what are you hacking on? 00:05
whiteknight nothing at the moment. I just signed on and am hunting for prey
dukeleto whiteknight: me too 00:06
soh_cah_toa so i have a few test files that i created in a separate directory in t/tools. isn't there some @array i'm supposed to add it to in some package? i forget the name
i think it's @library_tests or something 00:07
dukeleto soh_cah_toa: probably in the config/gen/makefiles/root.in file 00:08
soh_cah_toa oh wait, i think it's lib/Parrot/Harness/DefaultTests.pm 00:09
dukeleto soh_cah_toa: that is what is used to generate the Makefile. Or maybe that pm
soh_cah_toa it's so the tests are run during "make test"
NotFound soh_cah_toa: PBC_TEST_FILES 00:10
soh_cah_toa i fixed that pbc issue by just compiling the .pir file in testlib 00:11
NotFound "just"? 00:12
soh_cah_toa i fixed that pbc issue by compiling the .pir file in testlib ;) 00:13
NotFound "compiling"? ;)
dalek rrot/soh-cah-toa/hbdb: 7e5f19a | soh_cah_toa++ | / (5 files):
Renamed and moved test files into a separate directory and added them to the list of tests run with "make test"
00:19
00:30 Limbic_Region joined 00:31 rodrigo joined
dukeleto rodrigo: welcome to #parrot 00:32
dalek rrot: ab704f3 | Whiteknight++ | src/oo.c:
Remove one more methodcall to namespace from oo.c
00:34
NotFound whiteknight: please take a look at my comment on TT #2103 00:41
whiteknight okay 00:42
I really hate vtable MMD
hate it
NotFound I think we should ask if some HLL is using that vtable, and deprecate it if not. 00:43
whiteknight yes, I like that. Send an email to parrot-dev and parrot-users? 00:45
NotFound I think so. And comment it at next #ps
00:46 rodrigo left
NotFound "Does the same thing as the other cmp_* variants, but puts a PMC in $1. This is useful for avoiding the semipredicate problem in HLLs where two aggregate PMCs are not always comparable." 00:48
This is what the doc of cmp_pmc in cmp.ops says.
00:48 dmalcolm left
NotFound I doubt about the "useful" part if it always throws. 00:49
Also, my english isn't able to parse "semipredicate problem" %-) 00:50
00:50 theory left
dukeleto is glad his tests are useful 00:50
NotFound: yeah, the docs could be a lot more clear about what that means 00:51
dalek TT #2138 created by whiteknight++: Deprecate unnecessary NameSpace methods
TT #2138: trac.parrot.org/parrot/ticket/2138
NotFound Amazing, wikipedia knows it. 00:52
Given that definition, it looks like that op is trying to avoid throwing an excepction, and failing miserably on that task. 00:54
whiteknight NotFound: didn't you add a get_main method to the Packfile PMC? 00:55
NotFound whiteknight: not yet, only to Eval. 00:56
whiteknight oh, Eval. Gotcha
I'm hacking on Packfile PMC tonight. I'll look at adding it
and ability to look up other functions and constants
I want to start making PackFile able to replace Eval 00:57
and then I want to kill Eval
NotFound Sounds good. 00:58
dukeleto a big +1 to removing Eval PMC
NotFound whiteknight: I think there was a problem in order to locate main in a loaded packfile, the :main flag get lost somewhere. 01:00
whiteknight NotFound: I am going to un-lose it
NotFound Good.
whiteknight I'm adding set_pointer to Packfile PMC right now so IMCC can return it 01:02
IMCCompiler.invoke will continue to return Eval for backwards compatibility. IMCCompiler.compile() and .compile_file() are going to return Packfile PMC
so we can start upgrading people
NotFound I've made an amazinf discovery, there are people that sell wikipedia articles as books. 01:04
01:04 lichtkind left
dukeleto NotFound: sad little people they must be 01:04
NotFound $62.48 Paperback Book, 124 pages 01:05
Sad clients, I'll say.
dukeleto: TT #2048 isn't the same thing as TT #2103 ? 01:11
bubaflub ~ 01:18
whiteknight PackfileBytecodeSegment has a get_main method 01:22
but I cant figure out how to get at it from the Packfile PMC 01:23
soh_cah_toa whiteknight: i had the same problem several weeks ago 01:40
whiteknight and I hope you have a solution handy?
soh_cah_toa i'll let you know when you tell me :) 01:41
NotFound whiteknight: You mean main_sub? Doesn't look like doing the right thing.
whiteknight NotFound: I don't know if it is or not. I can't get it so I can't test it
no, it returns the INTVAL offset of the main_sub 01:42
probably the key for the PackfileConstantSegment PMC
NotFound There is a Parrot_pf_get_packfile_main_sub function 01:45
dalek rrot: ccadaea | Whiteknight++ | src/pmc/ (3 files):
misc fixes to LexPad so we can headerize. Headerize. Add a prototype set_pointer vtable to Packfile PMC
01:46
rrot: a59df70 | Whiteknight++ | src/pmc/ (2 files):
IMCCompiler.compile returns a Packfile PMC now. This is safe because the method is still experimental and nobody is using it
whiteknight Yes, but that works on a PackFile* wrapped in a PtrObj PMC
rrot: e0016a9 | Whiteknight++ | src/pmc/lexpad.pmc:
Add some ARGMOD stuff to lexpad PMC
whiteknight I think I want to redo the packfile PMCs 01:47
soh_cah_toa would be very happy
whiteknight Right now, Packfile and friends try to duplicate data from the PackFile structure, but don't duplicate it perfectly 01:48
I think a better design would be thin wrappers around PackFile* which use the PackFile* for storage directly 01:49
soh_cah_toa that's not a bad idea
whiteknight Then all we would need to do is add METHOD wrappers for existing src/packfile/api.c API functions 01:50
soh_cah_toa it would be a lot cleaner and organized that way 01:51
and reduce duplication which is always a plus
whiteknight Or, better yet, Keep the PackFile* stored in a PtrObj PMC, and write object wrappers in something friendly like Winxed, using NCI access on the packfile API functions
well, I don't know if that would be "better", but fun to think about
yes, I'm definitely not liking the duplication of the current PMCs 01:52
NotFound The problem is that PackFile structs are not intended for iterative creation, but the PMCs are. 01:53
01:55 JimmyZ joined 01:59 bubaflub left
soh_cah_toa this may be a little off topic but would any of you know whether the parrot.org stylesheet is an original creation or one of those free templates that come w/ cms's like drupal/wordpress? 02:03
JimmyZ knows that 02:04
whiteknight I have no idea
soh_cah_toa b/c i found a site that looks like a mirror image of parrot.org. i was just wondering if that was...well...bad 02:05
dukeleto soh_cah_toa: most likely a slightly tweaked drupal theme 02:18
soh_cah_toa: it is Drupal
soh_cah_toa ah, ok
02:19 whiteknight left
soh_cah_toa then this guy probably just used the same one, that's all 02:20
02:26 JimmyZ left 02:38 rurban joined 02:40 bubaflub joined 02:41 rurban__ left, contingencyplan left 02:56 Limbic_Region left 02:58 cotto joined
cotto ~~~ 02:58
03:35 redicaps joined 03:36 redicaps left 03:40 theory joined 03:49 theory left 04:44 bubaflub left 05:08 benabik left 05:28 soh_cah_toa left
cotto It's quiet. 05:53
sorear hi 05:57
I need a programming language which is fast, supports garbage collection with 6model-style STables, makes dynamic code generation easy, and offers good support for coroutines and stack introspection 05:59
06:00 jsut joined
sorear cotto: I wonder if what I want is Lorito 06:03
I beleive I brought this up before, but that was before YAPC::OR, and it sounds like you're bored now. 06:04
06:05 jsut_ left
cotto not so much bored as resting 06:13
but not resting so much I'm not up for talking about Lorito
sorear, do you need it now or in the foreseeable future? 06:14
sorear it's for a project I'd like to do. 06:15
I can put off starting it indefinitely
Go, Haskell, and $Lisp are on the table 06:17
cotto Lorito isn't a specific language as much as the combination of M0 and a MOP, though we'll need to figure out what M0 overlay language looks like if we want to avoid going insane from writing a bunch of M0 directly.
06:19 dodathome joined
sorear the main problem I have with C is expensive coroutines 06:19
yeah. I'm wondering if I could be helping the Parrot project by pioneering the use of M0 overlays and M0 VMs and 6model+M0 06:22
cotto Someone'll need to start on that soon. 06:23
sorear M0 promises efficient coroutines, JITless operation (another constraint I forgot), and easy dynamic code generation
cotto jitless operation? 06:24
Does that mean anything more than "doesn't have a jitting interpreter"?
sorear I mean "can it run at a reasonable speed without JIT startup costs" 06:29
cotto ok
sorear basically, I want to match 'time perl -E "say 2 + 2"' 06:30
cotto that's a good target 06:31
sorear the last Perl 6 implementation I did was C# based and it takes like 5 seconds just to JIT the parser
dukeleto ~~ 06:34
cotto hio dukeleto
dukeleto cotto: hola
cotto: looks like it will be in the 80's and 90's in Asheville for YAPC::NA 06:37
cotto dukeleto, that saves me from having to look that up. Packing for warm weather will be nice. 06:38
dukeleto cotto: it does say a chance of thunderstorms, which I am really looking forward to. I haven't seen a decent thunderstorm since moving out west 06:43
cotto There was a terrific wind storm in Chicago at yapc a couple years ago.
dukeleto, we need an M0 overlay language. thoughts?
06:45 mj41 joined 06:56 mj41 left 07:00 fperrad joined 07:31 daniel-s joined 07:34 daniel-s_ joined, daniel-s left 08:08 JimmyZ joined 08:17 rodrigo joined 09:02 Eclesia joined
Eclesia hi 09:02
09:16 lucian joined 09:30 daniel-s_ left
Eclesia NotFound: found a bug on resolving method on self, test case : pastebin.com/LUz9hahk 09:51
09:54 ambs joined
dalek rrot: 58eb810 | mikehh++ | t/op/lexicals.t:
remove trailing spaces
10:09
rrot: 438bf3b | mikehh++ | src/pmc/lexinfo.pmc:
remove trailing spaces, update copyright
rrot: acd2a95 | mikehh++ | src/pmc/lexpad.pmc:
add missing ASSERT_ARGS
10:14 daniel-s joined 10:33 Drossel joined
dalek rrot: 4f6855f | mikehh++ | src/pmc/imccompiler.pmc:
add missing documentation
10:35
rrot: 2410627 | mikehh++ | src/pmc/lexpad.pmc:
add missing function documentation
10:38 rurban_ joined, Kulag left 10:39 contingencyplan joined 10:41 rurban left, rurban_ is now known as rurban
NotFound Eclesia: winxed has no multimethods yet. 10:43
Eclesia ok 10:44
NotFound: how does 'boolean' values work ? since there is no 'boolean' type ? 10:46
NotFound Eclesia: you mean the builtin constants true and false? 10:47
Eclesia yes 10:48
NotFound Easy: true is 1 and false 0.
Eclesia if I want to store them, I must use an int then 10:49
10:49 redicaps joined
NotFound Yes. 10:49
Eclesia NotFound: in Exception class, severity level works in which way ? 0 is severe, 10 is not important ? 10:52
NotFound Eclesia: see runtime/parrot/include/except_severity.pasm in parrot 10:53
11:15 rodrigo left
mikehh All tests PASS (pre/post-config, make corevm/make coretest, make world/make test, fulltest) at 3_5_0-35-g2410627 11:17
Ubuntu 11.04 i386 (g++ --optimize)
Eclesia NotFound: the size of an array is not length(array) ? 11:27
NotFound Eclesia: no, length is string length. You need elements(array) 11:29
Eclesia thanks 11:33
NotFound: is there a method to remove trailing spaces on a string ? (try trim(str)) 11:37
tryed*
NotFound Eclesia: no 11:38
In general, winxed builtins just uses features already present in parrot. 11:39
Eclesia NotFound: so is there something like string.getChar(0) or string.startWith("...") ? 11:41
Eclesia to make this trim function
chr(out STR, in INT) 11:49
The character specified by codepoint integer $2 is returned in string $1.
but that's in pir, looks like the name changed in winxed
NotFound Eclesia: you can use substr, chr, and operator [] 11:50
And ord 11:51
But I don't undestrand why you may want chr for that task.
Eclesia well (in java) we have String.getCharAt(index) 11:52
chr definied looked like it was doing the same thing 11:53
definition*
but [] seems to do the same
NotFound chr gives you a one character string with the codepoint specified.
s[n] is syntactic sugar for substr(s, n, 1) 11:54
Eclesia: keep in mind that many people here are not fluent in java, so "something like java xxxx" is not a good description. 11:58
Eclesia NotFound: I can only compare with what I know. since I don't code in javascript or c/c++ . we certainly have very little common syntaxe to share 11:59
NotFound You can try gwbasic X-) 12:02
Eclesia NotFound: substr is (String, startCharIndex, endCharIndex) or (String, startCharIndex, lenght) ? 12:08
NotFound Eclesia: length
Eclesia ^^ one more difference with java
NotFound Eclesia: note that the string is not an object. The point is not to mimic some String class, wich is pointless because is not an instance of any class, but to translate directly to parrot ops, for speed and simplicity. 12:11
So in order to guess what winxed builtins do, you must think about the parrot ops. 12:12
Or even better, don't guess. Look at the source, and test. 12:13
Eclesia easy to say when you understand c/c++, pir, pod docs and where to find what you are looking for ... 12:15
NotFound BTW you can use methods of the parrot String class with winxed string type. The string is automatically boxed in that case.
Eclesia: testing is easy: winxed -e 'say(substr("hello", 1, 2));' 12:16
Try that with java ;) 12:19
Eclesia :p 12:21
can't compare parrot and jvm. debugger, profiler, IDEs, libs ... it's a different world 12:22
NotFound Aye
I just point that with more dynamic languages sometimes is faster to do a quick test than to look at the docs. 12:23
Eclesia in 6~10 years perhaps parrot will look like the current java ecossytem if oracle continues to destroy everything :D
NotFound I don't use IDEs anyway. 12:26
Last time I used and IDE it was Borland C++ builder.
an
Eclesia can't imaging developing a big project without proper code refractoring, syntaxe highlight or files over 2000 lines 12:28
NotFound: I have declared a function in a namespace (pastebin.com/xJSjM8Q9) . now I want to use it, I write Strings.trim(...) 12:30
NotFound: what is the correct writing to call it ? 12:31
NotFound Winxed stage 1 is now at 10004 lines. Too big for my taste, but in the current state keeping it as one big file is convenient,
Eclesia already have 6 winxed files for eria, all less then 100 lines 12:32
found it : using Strings.trim; 12:36
NotFound: it's not possible to avoid writing it before calling it ? 12:37
NotFound Eclesia: you can also use: using Strings.trim; .... trim(....)
Eclesia: if you load it from other file, using is the way to go. Declaring external functions is not implemented yet. 12:38
$load "Strings.pbc"; 12:39
function main()
{
using Strings.trim;
say("<", trim(" hhh "), ">");
}
This works.
Eclesia NotFound: I have heard of namespace and frame. do you have a minute to explain the different ways to express a 'scope' in parrot ? 12:47
12:50 redicaps left
NotFound Not sure what you mean by 'frame'. In what context you hear it? 12:53
12:54 jsut_ joined
Eclesia somone talked about it about nqp 12:54
NotFound Probably is lexical related. 12:55
Eclesia don't know. 12:57
NotFound I don't know much about nqp, I can explain how winxed does things and its parrot basis.
Eclesia I would be grateful if you could explain even a little :) 12:58
12:58 jsut left
NotFound Parrot namespaces can contain subs, variables and other namespaces. You can use the get/set_global family of opcodes to look in the current namespace, the base namespace of the current HLL, or the parrot root namespace. 12:59
Winxed uses also a less dynamic approach: for functions defined in the current file, it search the scope and statically bind the functions located. 13:00
And you can use "using" and "using namespace" to expand the scope search. 13:02
This ways are borrowed from C++.
You have some extreme examples in winxed t/advanced/10scope.t 13:03
Eclesia is there a way to hide a sub/var in a namespace ? like for example I want this sub to be available only by those in the same namespace
NotFound I use this convention: namespace __private { define things } using namespace __private; 13:04
Eclesia are there other ways to express a scope ? you said lexical a bit before 13:06
NotFound But this makes the __private part available only to the current namespace in the current file, not when using the same namespace in other file compiled apart.
Lexicals are a different beast. The lexical context of a sub is defined with the :outer modifier, and lexical variables are looked up by name. 13:08
In nqp and rakudo, blocks inside a sub are compiled to separated subs, kept togeheter by :outer and sharing variables by lexical means. 13:09
Winxed is different in this regard, it uses lexicals automatically when anonymous functions use variables declared in the function where they are declared. 13:10
Where the anon function is declared, I mean. 13:11
for example: function a() { var i = 10; var f = function() { return i; }; return f; } ..... var x = a(); say( x() ); ---> prints 10; 13:12
i defined in used fron the anonymous function returned, wich really is a closure. 13:13
Eclesia digest all this (make take several minuts) :D 13:16
may*
NotFound Winxed does not do that for other kinds of blocks, like nqp does, because it doesn't genearte independent subs for them. Block scopes are completely handled at compile time. 13:17
13:18 fperrad left
NotFound Eclesia: don't worry, it took months for me understand parrot lexicals enough to be able to implement that in winxed. 13:19
13:20 fperrad joined
Eclesia is actually searching for the correct way to define scopes like 'private, protected, public' 13:20
NotFound Eclesia: I plan to eventually implement that in winxed, but don't have yet even a clean path in mid. 13:21
AFK for a while. 13:27
14:08 rohit_nsit08 joined 14:17 jsut joined 14:22 jsut_ left 14:27 Eclesia is now known as Eclesia_afk 14:42 bubaflub joined 14:52 Eclesia_afk is now known as Eclesia
dalek nxed: r1061 | NotFound++ | wiki/Winxed.wiki:
Edited wiki page Winxed through web user interface.
15:09
tracwiki: v151 | NotFound++ | Languages
tracwiki: Chaged Winxed repository
tracwiki: trac.parrot.org/parrot/wiki/Languag...ction=diff
website: NotFound++ | Migrated winxed to github
website: www.parrot.org/content/migrated-winxed-github
JimmyZ NotFound: winxed.org is not updated 15:11
NotFound Take it easy. 15:13
cotto ~ 15:15
NotFound, nice
15:25 zby_home_ joined 15:27 zby_home left 15:29 rohit_nsit08 left
NotFound http:/winxed.org/ updated. 15:32
15:34 whiteknight joined
JimmyZ NotFound++ 15:35
whiteknight NotFound++ 15:37
cotto I like that song. NotFound++ 15:38
PacoLinux NotFound++
dukeleto NotFound++ # yay, winxed is in git 15:40
NotFound: will you be using Github issues for Winxed? 15:41
NotFound dukeleto: I suppose so. 15:42
15:42 daniel-s left
Eclesia don't see what's new on the winxed site 15:44
NotFound Not much.
16:06 estrabd left
Eclesia can some tell me why parrot complain when compiling this : pastebin.com/bQaeapig ? 16:13
error:imcc:syntax error, unexpected ANNOTATE, expecting $end ('.annotate') 16:14
in file 'target/Function.pir' line 1
error:imcc:syntax error ... somewhere
NotFound Eclesia: unfortunately, annotations must be inside subs
Eclesia ok 16:15
cotto You can't have executable code outside a sub in PIR, so it doesn't make sense to put annotations there.
Eclesia I was thinking annotation were like 'description' of what is following
cotto In the future, please use a nopaste without ads such as nopaste.snit.ch 16:16
aloha, nopaste?
aloha cotto: nopaste is is nopaste.snit.ch (works with the script in $_PARROT/tools/dev/nopaste.pl)
Eclesia ok 16:17
nopaste "Eclesia" at 192.168.1.3 pasted "test" (1 line) at nopaste.snit.ch/54746 16:18
Eclesia nice :)
16:21 GodFather joined
cotto They expire after a while (a week or so iirc). If you need something to be stored for longer, gists are really nice. 16:25
Eclesia .sub Winxed_class_init :anon :load :init <-- As I understand, this creates a new object. does the sub name matters ? 16:33
NotFound Eclesia: the purpose of that subs is to create the classes at load time. The name is not importante, it's :anon 16:35
16:35 rohit_nsit08 joined
cotto Those modifiers mean that the sub won't have an entry in the namespace, will be loaded when the file it's in is loaded as a library and will be run first when the file is run directly. 16:35
Eclesia i don't yet see the difference exactly. if I only one of them. what would that mean ? the three names are similar to 'on load/start/init' 16:41
:anon stands for what ?
(sorry for my awful english) 16:42
cotto "anonymous/'
NotFound Anonymous
cotto s./..
Eclesia a sub anonymous ... what it's purpose ?
ho i see, not being useable later, only used when file is loaded 16:43
16:43 cjh joined
NotFound In this case, the sub is intended to run automatically just one time, so there is no need to put it in a namespace. 16:47
In general, :anon can be used later, by its subid. 16:48
whiteknight has a present for soh_cah_toa 16:54
Eclesia victory! first (empty) class generate ec > pir > pbc
dalek rrot/whiteknight/packfilewrapper: c1055bc | Whiteknight++ | src/p (4 files):
Create new packfile API functions Parrot_pf_new (PackFile_new) Parrot_pf_destroy (PackFile_destroy), Parrot_pf_serialize_to_string and Parrot_pf_deserialize_from_string. Add new prototype PackfileWrapper and PackfileManager PMC types
sorear :anon is useful when you're writing code and don't want to worry about namespace hell
opbots trust Eclesia
slavorg Ok
slavorgn Ok
16:55 cjh left
whiteknight Eclesia++ 16:55
Eclesia is there a concept of 'module' in parrot ? 16:58
forget it, namespace can replace it 16:59
17:02 rodrigo joined
Eclesia NotFound: is it possible to extend a parrot class in winxed ? 17:16
NotFound Eclesia: You mean inherit from it? 17:20
Eclesia yes
NotFound Yes, you can do for example: class MyArray : ['ResizablePMCArray'] { .... } 17:21
Eclesia thanks
17:28 GodFather left 17:29 rohit_nsit08 left
dalek kudo: 4f47105 | (JD Horelick)++ | docs/announce/2011.06:
Update 2011.06 announcement with the releasename and another Douglas Adams reference.
17:35
kudo: 70c5ca4 | (JD Horelick)++ | docs/release_guide.pod:
Update release_guide.pod for 2011.06 release.
kudo: b2bc994 | (JD Horelick)++ | VERSION:
[release] bump VERSION
kudo/nom: 7bfc64f | jonathan++ | src/Perl6/Metamodel/BOOTSTRAP.pm:
Get PROCESS in place. Should only ever have one of these.
17:37
kudo/nom: baf7677 | jonathan++ | src/Perl6/ (2 files):
Make things like $PROCESS:IN = ... work.
Eclesia is it possible in pir to indicate we want a var to be of a given class ?
(objective is to have an error if we try to assign a value of a different type in it) 17:38
17:40 JimmyZ left
Eclesia perhaps something like : .annotation 'enforceType' , '....classname' 17:40
whiteknight no, nothing automatic like that 17:41
there is an "isa" op, that you can use to check if an object is a given type
so you would use something like if(!isa(obj, expected_type)) { throw "All hell breaks loose!"; }
isa is a PIR op. it may be a winxed built-in too 17:42
Eclesia yes, but since anyone can modify a var in a class, I'm not sure someone who uses them mess up.
whiteknight of course, annotations can be used to store arbitrary key/value pairs, so you *could* write your own mechanism to do that
Eclesia whiteknight : you mean it's possible to write something which would be pluged in parrot. add check each time the value is affected ? 17:44
could*
and*
whiteknight no, not plugged in to parrot. You could write your own function to read annotations, take an object and a key, and verify that the object matched the type specified by the key 17:45
although that seems like the hard way to do it
also, there is a "can" opcode which tests whether an object has a certain method
the type of the object doesn't matter as much as the interface
dalek kudo/nom: 2c533ea | jonathan++ | src/Perl6/Actions.pm:
Fix GLOBAL lookups.
17:57
kudo/nom: de38225 | jonathan++ | src/Perl6/SymbolTable.pm:
Was a little to eager in lexical => lexical_6model; still need to look for lexical in the odd place. Unbusts some lookups.
rrot/whiteknight/packfilewrapper: fc5776b | Whiteknight++ | / (7 files):
PackfileWrapper -> PackfileView. Fixes so we can build. Headerizer. Add some functionality to PackfileView to match or exceed what Eval provides in terms of getting access to constants and Subs
18:00
cotto whiteknight, what's your plan in that branch? 18:04
whiteknight cotto: Replace Eval. Make IMCC return a custom PMC type instead of a dumb 18:05
PtrObj
I would also like to start moving the current Packfile* PMCs out of core into a bytecode-building dynpmc lib
but that's a deprecation cycle away,at least 18:06
sorear make sure there's a migration path suitable for PCT::Compiler
whiteknight sorear: Yes, definitely. Should already be
sorear compile-and-run mode uses Eval
whiteknight IMCC returns a PMC with a PackFile* struct pointer in it. Then, we wrap it in an Eval PMC and return it. That's what we do now
So I changed out the first PMC type used, but we're still returning an eval
If we have $P0 = compreg 'PIR', invoking $P0 directly returns an eval. Calling the newfangled .compile and .compile_file methods returns a PackfileView instead 18:07
so that's the migration plan. Stop invoking the damn compiler directly and treat it like an object, like all other compilers are
so we deprecate IMCCompiler.invoke vtable, migrate to .compile() method, all is well with the universe 18:08
sorear you'll have to add a runtime warning, because it's impossible to usefully grep for $P0() 18:09
whiteknight The new PMC offers the same capabilities as Eval: Get the main sub, get subs by index, etc. It also offers easier serialization and deserialization, save to file, access all constants (P, N, and S), etc
sorear: of course. I'm making alternatives available now. In no big hurry to start ripping out the old
We need the alternatives in, used, tested, documented, etc before we start talking about removing anything
What I like now is that with a single Packfile PMC type, I can call the compiler, get back a PMC, and write that same exact PMC to file without any fuss 18:11
viola! a .pbc file 18:12
or, take what the compiler returns, get the main function, and execute it
or take what the compiler returns, look up an arbitrary function in it, and execute that
manually trigger the :load functions if needed, or the :init functions too
What's the process for adding a new PMC? I added those two types but the system doesn't seem to recognize them 18:17
Eclesia lastindexof <-- does not exist ?
cotto whiteknight, pmcrenumber? 18:18
whiteknight hmm, that's not in make help 18:19
or dont read not good
Actually, I don't think its in there
No love 18:20
Class 'PackfileManager' not found
The types are getting registered at init time. I see them in the code at src/core_pmcs.c 18:22
And all the constants like enum_class_PackfileManager exist in the code
18:24 cjh joined
cotto looks like reconfig 18:24
dalek kudo/nom: c66a42a | moritz++ | src/core/IO.pm:
update IO.say
18:25
kudo/nom: a67ebc3 | moritz++ | src/core/IO.pm:
set up $*IN and $*OUT
whiteknight ah, nevermind. Wrong parrot 18:26
uninstall made my problems go away
SUCCESS! 18:27
I <3 Parrot
this is going to be a good day, if I can start getting this all working correctly and get some tests going 18:30
cotto: Another thing I am doing is working on the packfile subsystem API: Bringing functions up to naming standards, and hopefully getting non-api stuff moved into other files for clarity 18:34
so the cleanup work is a big deal too
cotto I saw. The awesomeness is increasing. 18:35
whiteknight++
whiteknight The current packfile PMCs try to duplicate or replace PackFile*, but it's not complete 18:37
and I don't think it easily can be. They're useful for creating new PackFiles, but not great for representing them in normal use in a program 18:38
getting back from a compiler, examining values from it, writing to file, etc
18:38 rurban_ joined
whiteknight With this, we get to the point where we can start writing the frontend/parrot/main.c frontend in PIR itself, with far less C bootstrapping 18:40
18:41 rurban left, rurban_ is now known as rurban
whiteknight and proper PIR-based exception handling 18:41
cotto srsly?
whiteknight srsly
cotto WANT
whiteknight In fact, I might put together an example using pbc_to_exe tonight
cotto What about the options that effect interp init? 18:42
Are you going to have a parent interp take care of those?
whiteknight that's the small amount of bootstrapping code we would need 18:46
cotto Are you thinking about how to avoid that if it's not needed? Starting two interps won't help startup time. 18:48
whiteknight gist.github.com/1046768 18:49
not two interps. Same interp
we just jump into PIR code earlier. We do less initialization in C, then jump to PIR and do the rest
that's a quick gist I put together with the new PMCs
we can do compilation from PIR. Maybe even load in IMCC from PIR if we set up that kind of code 18:50
we have a lot of work to do still
19:02 rodrigo left
Eclesia what is the method to clear a Hash (remove all values) ? 19:08
and how to iteratare on all key/value pair in winxed ? 19:10
iterate*
NotFound Eclesia: for (key in hash) 19:12
Eclesia ho like a array 19:13
an*
cotto Eclesia, C or pir? 19:15
or nqp
Eclesia cotto: winxed :D
cotto ok
whatever NotFound says, then 19:16
Eclesia cotto: if you have pir, that should be close
NotFound There is no direct way to clear, but you can do: hash.set_value_type(hash.get_value_type())
The for loop gives key, to get the values you can use the same ways as in pir.
19:17 rohit_nsit08 joined
Eclesia NotFound: is there a 'null' pmc ? 19:17
NotFound Eclesia: yes
But there ins no need to instantiate it, you just need to set a pmc register to null. 19:18
Eclesia NotFound: I can do that on any type (string,var, ...) if(value == null){ ... } ? 19:19
NotFound Only with string and var.
Eclesia number type are set to 0 by default ?
NotFound Yes.
Eclesia ok
19:25 whiteknight left, whiteknight joined 19:32 rodrigo joined
Eclesia NotFound: if(self.attributeMap[attId] != null) <<--- this is always true, even if the key does not exist. normal ? 19:32
dalek kudo/nom: 4f8a6d9 | moritz++ | src/core/IO.pm:
set up $*ERR, jnthn++
19:34
Eclesia whiteknight: if you know ? 19:35
NotFound Eclesia: not normal. 19:36
Eclesia (attributeMap is a Hash) 19:37
NotFound Eclesia: I can't guess what's happening just with that line. 19:39
Eclesia NotFound: I am writing a simple test
hm... must be on my side, work in the test 19:44
19:45 whiteknight left, whiteknight joined 19:50 whiteknight left
dalek kudo/nom: 348b506 | moritz++ | src/core/ (2 files):
make say() and print() redispatch to the methods on $*OUT
20:03
nopaste "Eclesia" at 192.168.1.3 pasted "hash and != bug" (14 lines) at nopaste.snit.ch/55018 20:06
Eclesia NotFound: here it is
it should print "ok" but it doesn't 20:07
NotFound Eclesia: parrot hash by default have string keys and PMC values. Asking for a string in this case gives an empty string, not a null one. 20:15
Eclesia should be null
an empty string is not the same thing as a null. 20:16
NotFound Eclesia: I think so, but winxed just reflects what parrot does, 20:17
Eclesia looks like an ungly hack to avoid null checks later in the code :/ 20:18
-n
NotFound You can use the exists operator. 20:19
Eclesia NotFound: is there a method containKey(key) ? this way I could bypass the error
NotFound if (exists map[key]) .... 20:20
Eclesia NotFound: you're too fast ^^
NotFound No method. There are the exists_keyed... vtable functions, wich is what the winxed exists operator uses. 20:23
20:23 fperrad left 20:28 autark_ joined, autark left 20:29 autark_ left, autark joined 20:33 dodathome left 20:40 ambs left 21:00 krunen left
Eclesia finally parsing, something that looks like a real class :) nopaste.snit.ch/55036 21:03
sorear Eclesia: ooh, cool, what are you working on? 21:05
Eclesia something between a vm and a syntaxe. eria model 21:06
you have a set of class describing paradygms
and you provider a parser to transform code in those. which are then compiled to code
from experience, no syntaxe is perfect, some like script are better for short programs, but other generaly static typed are better for back end. 21:08
and for science they use other syntaxes, like math expressions 21:09
but whatever syntaxe, all projects always have the same organisation
so eria is here for that, provide the standard way to describe and organize. but leaves the developer the choice of the syntaxe
that's the idea ^^ 21:10
21:11 whiteknight joined
sorear There's no e in syntax in English, btw 21:12
Eclesia was wondering about this one
thanks
sorear syntaxes is correct however 21:13
21:13 rodrigo left, rg joined, rg left
moritz Eclesia: is your native language a romanic language? 21:19
Eclesia moritz: french
dalek kudo/nom: b9b7f54 | jonathan++ | NOMMAP.markdown:
Remove a completed entry from nommap.
Eclesia why ?
kudo/nom: f83b81d | jonathan++ | / (2 files):
First simple cut at our-scoped variables.
moritz Eclesia: because I thought "sticking and 'e' at the end is so French", and then I thought it could be any other number of languages too :-) 21:20
NotFound Ils sont fous, ces franƧais! 21:22
Eclesia we truly are :D
moritz: at least frenches make good cheese :p 21:26
NotFound With and 'e' at the end. 21:27
dalek p: 2f91679 | pmichaud++ | src/HLL/Compiler.pm:
Remove long Q:PIR section from HLL::Compiler.command_line().
21:29
p: 21aa0e4 | pmichaud++ | / (4 files):
Merge branch 'master' of github.com:perl6/nqp
Eclesia parrot doesn't talk french ?
21:31 rohit_nsit08 left
whiteknight Eclesia: no. I had an idea for i18n support a while ago, but there wasn't enough agreement about it 21:32
Eclesia maybe I should make my parser for french ... syntaxE , classE, methodE ... would be fun 21:34
cotto le parser 21:38
NotFound You can also rename the docs about methods as "Discours de la mƩthode"
Eclesia cotto : parseur*
cotto It's American French. 21:39
;]
Eclesia american only have french fries and fench kiss ;) 21:40
+r
cotto and parsers, now 21:41
NotFound feels like inside 'Pulp fiction'
cotto I just watched that again today.
NotFound Le Big Mac, s'il vous plaƮt.
21:42 Psyche^ joined
cotto sadly, "nom" already means something else in French 21:42
Eclesia Un* Big mac
cotto again, American French 21:43
Eclesia 'nom' means something is english ?
in*
cotto Eclesia, only on the Internets: knowyourmeme.com/memes/om-nom-nom-nom 21:44
21:46 Patterner left, Psyche^ is now known as Patterner
Eclesia hm... never heard of it 21:47
dalek p: faf34e9 | pmichaud++ | src/HLL/Compiler.pm:
Eliminate obsolete "astgrammar" stuff from HLL::Compiler,
cotto It also stands for "new object model" if you see it in the context of Rakudo or nqp. 21:49
Eclesia I don't intend to see or touch rakudo or nqp anymore :D 21:50
NotFound Eclesia: By the way, wich language are you working on? 21:55
Eclesia NotFound: you mean : at work, for the parser or for the parsed file ? 21:56
NotFound The parsed file. 21:57
Eclesia eria
NotFound Like in "Eria is a large genus of orchids with more than 500 species..." ?
Eclesia something like that ^^ it's a multi syntaxic model 21:58
NotFound The only result that seems relevant I get from google is only available on cache, looks like its domain got lost. 22:00
Eclesia it's because I have the only here. 22:01
have it* 22:02
NotFound Ah, nice.
Eclesia if you found this eria thing of google code. you can be sure it's not me. (hate google)
22:03 soh_cah_toa joined
NotFound No, it was eria.wikidot.com 22:03
Eclesia that's it ^^. but removed everything a few weeks ago 22:04
damned google cache
fortunatly it's not everything
NotFound You are not in touch the times. The trend is to first make a bunch of websites, and maybe later start working on the project ;) 22:06
cotto How can you create a product that you haven't marketed first? 22:08
Eclesia they are just fools, talking and advertising before having something in hands is for commercials and egocentric developers. 22:09
I dont intend to make money or fame from it. I want to replace java (only that ...) 22:10
tadzik :) 22:11
cotto oh. That's all.
tadzik yeah, simply this
Eclesia that's all lol
remember : frenchs are fools ;) 22:12
NotFound Again out of trend. The current fashion is trying to replace facebook.
soh_cah_toa does anybody know if there's some sort of "proof of purchase" ticket i need in-hand to get into the yapc::na conference area? i've paid for my ticket but when i get there, how do they know that i've paid? 22:13
Eclesia believe social networks are just a waist of time 22:14
waste*
NotFound soh_cah_toa: they know all perl developers are trusted people and you'll not lie to them.
22:14 autark left
soh_cah_toa really? 22:15
NotFound I'll not lie to you ;) 22:17
cotto You pretty much tell them your name. It's a laid back conference in that aspect. 22:18
soh_cah_toa ok 22:19
cotto Technically it's exploitable, but in reality there's not that much benefit.
If you care about getting into the conference, you probably care enough to support it by paying.
soh_cah_toa that's true 22:20
cotto For something like OSCON, I can see a much stronger incentive to hack the system. 22:21
soh_cah_toa really? why's that? i don't know much about OSCON 22:22
cotto check the admission prices 22:23
It's much more corporate. 22:24
soh_cah_toa :O
wow!
cotto (note that I'm not advocating hacking your way into oscon)
dalek kudo/nom: 706682b | jonathan++ | src/ (3 files):
Fix roles in pre-compiled situation, so they work as well as in immediate-run mode.
22:32
kudo/nom: dbdb675 | jonathan++ | / (6 files):
Add empty Associative and Positional roles; make List/Parcel/EnumMap do them appropriately.
kudo/nom: cc24038 | jonathan++ | NOMMAP.markdown:
Remove done items from nommap.
whiteknight soh_cah_toa: did you see my new branch? 22:38
soh_cah_toa whiteknight: no, show me
whiteknight github.com/parrot/parrot/compare/m...ilewrapper 22:39
the important part is the two new PMC files
soh_cah_toa oh yeah. look at that... 22:40
dalek rrot/whiteknight/packfilewrapper: ed91e9e | Whiteknight++ | src/pmc/imccompiler.pmc:
fix typo. IMCCompiler.compile should return a PackfileView,not a Packfile
22:41
rrot/whiteknight/packfilewrapper: cd54756 | Whiteknight++ | / (5 files):
Steal logic from Parrot_api_write_bytecode_to_file to create Parrot_pf_write_pbc_file. Use that function to implement PackfileManager.write_to_file. Also, remove PackfileView.execute method, it doesn't work as-is and can be easily replicated using main_sub()
moderator Parrot 3.5.0 "Menelaus" released | parrot.org | Log: irclog.perlgeek.de/parrot/restoday 22:42
whiteknight Let me know if you have any suggestions or requests while I'm adding new features 22:42
I want to make sure what I am doing works well with what other people are doing too
jnthn__ Does Parrot_str_new_constant add to the constant pool every time it's called?
soh_cah_toa so far, i'm liking t
*it
whiteknight jnthn__: Does it add to the constant pool at all?
jnthn__ Or does it cache based on the constant string?
whiteknight: I don't know
whiteknight: I'm trying to make sure it doesn't make a new string every time it's called and then never throw it away. 22:43
whiteknight: Otherwise line 716 of core.ops leaks
whiteknight github.com/parrot/parrot/blob/mast...api.c#L611 22:44
no
adds the string to the constant string hash, if it doesn't already exist
soh_cah_toa whiteknight: oh yeah, this is very nice
whiteknight soh_cah_toa: I'm glad you like it! 22:45
jnthn__ whiteknight: Ah, OK, cool :)
22:45 pjcj left
soh_cah_toa you code so fast! you were just talking about this last night. i'm jealous ;) 22:45
whiteknight soh_cah_toa: I code normal speed. I just know a lot of the stuff I need to write without having to look things up 22:46
things always go faster when you're more familiar with the system
soh_cah_toa yeah, having to look everything up definitely slows me down 22:47
whiteknight soh_cah_toa: Spend many many many more days and nights staring at this code while drooling on your keyboard, and you'll be doing it just as quick
I have to run out and get dinner. I'll be back later 22:48
soh_cah_toa see ya
Eclesia has won his full day on parrot, a colorfull with correct error message for the compiler : ftp://ftp-developpez.com/jsorel/temp/eriaCompiler0.png 22:49
0:50 ... time to go to sleep
bye all ++ 22:51
22:51 Eclesia left
bubaflub incoming 23:00
dalek rrot-gmp: fa43cd9 | bubaflub++ | t/integer/fits.t:
add tests for fits functions

this covers mpz_fits_slong_p, mpz_fits_uint_p, mpz_fits_sint_p, mpz_fits_ushort_p, and mpz_fits_sshort_p
rrot-gmp: e36e70b | bubaflub++ | t/integer/sizeinbase.t:
add tests for sizeinbase

this covers mpz_sizeinbase
rrot-gmp: 28a462a | bubaflub++ | t/integer/size.t:
add tests for size functions

this covers mpz_size
rrot-gmp: a97ead0 | bubaflub++ | t/integer/getlimbn.t:
add tests for getlimbn functions

this covers mpz_getlimbn
23:06 lucian left 23:19 pjcj joined
dalek rrot: cd9fe1b | NotFound++ | src/pmc/hash.pmc:
rearrange a bit and fix pod in Hash
23:28
23:28 daniel-s joined