Bestand wählen
Merken

Leapfrogging the bootstrap

Zitierlink des Filmsegments
Embed Code

Automatisierte Medienanalyse

Beta
Erkannte Entitäten
Sprachtranskript
interoperable operability with other languages the so a module may hook into news mechanism and we can actually use the statement 2 little 4 5 markets and we don't even need the P 5 object animals and the the thing that does not yet work it is important symbols that's the load of modular exports so and the going this here manually yes but other than that there almost cannot tell the difference to a native call 6 model but can when you literally use April 5 model using this In the MPO 5 Our creates the Perl 6 package corresponding with the for all 5 model and in this package it creates wrappers for all functions and methods that the profile module provides and you can use this just as if it was the Perl 6 method and With this except for the use in Lempel 5 it very much looks like a basis for all 6 model so at this that we have access to a lot of c can already fonts some modules require you to actually subclass them to use them so how do we some classes for all 5 class in all 6 well In land profile provides a Call 5 parent rule by consuming this role you tell in profile that Europol 6 class should acts like a subclass of a poll 5 classes um in memory at the pre much looks like this you have the full 5 this class object and is wrapped in a call 6 subclass object and whenever a method is called when this post 6 object the provides itself or delegates bound to the underlying profile of object and this works regardless of the call of being pulled 6 code or profile cool because if we pass this for 6 object to call 5 code it gets wrecked another time the full 5 wrapper object so not so wrapping lots of validating and that's why I call this inheritance by delegations so with this you can use for example what basic part which requires you to subclasses to implement its behavior so as you can see we just using unqualified we lost of the 4th model and have called six-part class consuming the pull 5 parent role and telling it and what sort of base class then it can just wrong and implements some methods like the set of but gets called whenever some someone say something on the IIsi gender and this is also where we implement the behavior of of all so when we agreed that we agreed back and if they asked to leave and quick so starting the box is just a matter of copy and paste from the bot basic of documentation modal some syntax changes the largest difference is that we have an additional arguments to the constructor passing of P 5 object and then rerun it's and if this was a pure advertising talk the probably stop here but there's some gotcha it turns out that in Perl 6 every class is a subclass of New and this new class provides the same so you can just say any object in course 6 and get some the sort of opera as a told you earlier this inheritance but the legation delegates all unknown methods to the underlying for all 5 objects but saves not unknown Drupal 6 object so in this case you have to be a bit more explicit and provide a say method yourself bands yeah refined old friend the invoke method again this is just copy and paste from the pole 5 parent role really this is what it does when you call a method the test so let's have a look at another example using HTML parser looks really just like the basic for example we again used call 5 parent role 2 subclasses impulse 6 now if if used HMM positive for neural might throwing that we don't actually have to subclass to use you can also passenger some cold references to implement the behavior and inland profile would actually support this but it's again no there's a small problem only H. power so it is implemented in excess and this kind of inflexible into really wants to see a cold reference there but England profile supports called references by creating a profile objects that overrides the the call operator and just 0 0 0 this is no cold preference I cannot call this evening it could the the so the the this these are just the methods let me right and we have to say it's actually good good via a subclass because I think this is actually
much nicer cold they have really methods we have method signatures temporal 6 so we don't really need this so called reference Mac-only mechanism that about possible wives and here we see 1 of my there all 6 features strings like content having to invent method that can actually outspend just as much as possible and then indent again and then this before in Perl 5 using regular expressions and it took me like 20 tries to get it right and here it's just they provided method so to finish this up in running the operative printer which develop parser example of this pretty much as straightforward as you can imagine it's just passing the prof 5 object called methods and so I would really like to stop here again but there's another culture it turns out called 6 objects have an n-dimensional it's implemented by the list class so you might desk what does he what does lists have anything to do with this we don't feel listed but as more it's explained to me Anderson general Perl 6 intentionally confuses lists of size 1 with scalar to do have an and so if you use XML parser using an just make sure that you always have your own and methods otherwise you will get strange error methods error messages about and being called with the wrong number of arguments took me a while to find the so equipped with this knowledge come back to catalyst you will say 0 it's just a matter of rings and repeat and to use Perl 5 and again and we can write catalyst controls imposed 6 in would problem look like this but it's that's not enough because catalyst is based on moose nowadays and it uses class mobs introspection capabilities to find the action methods and information about how to map your else to these actions and so and the information about how to map your else is contained in separate in activities but all 6 does not have separate punitive you and class more only can deal with classical itself created so what I did was right replacement for class mark called across 6 more if you can read the slide don't worry because the call 6 or 8 supports introspection so all really had to do is write a couple of one-liner methods that map the class API recall 6 introspection API but with this I was already able to hold out a Perl 6 class as a catalyst control and this will be actually enough to use pool 6 in Capon's based projects but I mean not exactly enough because there's 1 other question if it's missing from what about the separate reviews so-called 6 does not have subroutine attitudes book that has a more generic mechanism called traits the traits allow to attach meta information to all kinds of objects including methods so I wrote that qualify at tributes role and uh trait which we can use to attach just information that we need to our action methods and the class there all 6 mark class mock replacement uses this information to pass to capital and now catalyst actually knows how to map euros to all-pole 6 methods which well it is enough Jews catalyst and yeah it's enough but there's still 1 find it annoying issue catalyst automatically across loads models from the model view and controller namespaces of their applications and of course it expects this these models to be written in Perl 5 so you'd have to them the so in parallel of April 5 class tree in the 6 class trip and the pull 5 classes probably look a lot like this the just a lots of boilerplate and followed by some loading of Perl 6 module and ability the but that's a solution for that to England profile automatically creates a prof 5 package called me succeeding lines and by using the 6 online you can hand over the rest of the file to call 6 for processing and repairs we can have or people 6 implementations of controls models and use in the fires that catalyst ultimate who loans for us and it also provides my most favorite feature FIL look closely at the bottom of the snow static 1 1 the because the May 6 in land is actually implemented as a source filter and it replaces all your Apollo fix cope with the static 1 the and source for the 30 year elementary everything but there evil because they cannot sector but you do not want to use any other source for those with impulse 6 cured they don't need that so I guess in this case it's kind of OK it so I'm preparing flow of tried to do a live demo just like and things of that if you could be written in a very small catalyst application using these mechanisms and and
this world application uses a Perl 6 grammar through porous and AW starts hedge fund read out the statistics information and uses the
prospects 6 as switching module this claim as graph the book so I've shown you a lot of things that do work in mental 5 so let's talk a bit about what does not work obviously source written in profile would be highly surprised encaustic scope and so those out of the question but probably everything in the babble namespace is a bit too low level to be of any use in a Perl 6 program and of course everything in the polls 6 namespaces kind obsolete having a real process extent the loss and of we I will of all excellent question I did not have this use case gets that's not implemented um but it's you know I O is very object-oriented being called 5 nowadays so you can just pass objects back for that reply Cairo object so I guess it would actually work quite nicely of course terms of forms from both call 6 and 12 5 code will run at the native speaker so at the cost and performance is whenever you switch between those languages recall April 5 methods from call 6 have a small overhead in what I guess if you call a lot between those languages you should rethink your architecture because if this overhead is large part of your performance cost then thing you call can only be run the run a small so it's probably easier to port small fits the um back to limitations SUC in introspection issues some interesting challenges But challenges that can be overcome so another question you may ask this order alternatives a the people and I'm glad you asked this question is because indeed there are and they need 5 package for Perl 6 is a reimplementation of call 5 written in Perl 6 users of politics grammar the possible 5 cold so it passes this cold and turns it into the same abstract syntax tree as native people 6 Co so can go have all the benefits of for 6 cold like optimization and just-in-time compilation and threading support what it does not do is any kind of excess and never really it also does not feel very relevant of on that will they're kind of parsing interference so and to get all the nice performance characteristics that such as if you can get away with it use me 5 instead of Finland qualified but if you hit the wall so to say can you can always turn to inland profile and this another alternative that is the last 1 you know what I would like the in indeed I can do it in a well maybe their model and you want to use is not written in Perl 5 all maybe maybe it's a Python Martin and but there are certainly 1 Python module I really would like to use it's so cute findings and if you're a kid user you've probably heard of cute it's a C + + library that's amongst other things responsible for rendering user interfaces in KDE and some Windows applications and even on Android nowadays over the years there have been quite a few attempts to create crawl bindings for q but they all kind of share the same fate they ended up being incomplete and unmaintained that Python bindings however are maintained by the cute maintains himself so there are up to date and they do work so I would like to steal and England Python to the rescue so if a states with me so far this is not very surprising code in Inland Python module it has a run method you can pass it some code subclassing which is very important for right user interfaces Rex just the same as in in Lempel there's a python parent parent role of you can pass the base classes and as you can see here that supports multiple inheritance just like that of the profile controlled well implementing methods very straightforward this is some copy and paste from the pipe cute for tutorial that of adaption of syntax but not much the amount of another method that also shows how tool called Static 1 class of methods in Python at and then the last but not least running the application again pretty straightforward copy and paste from the tutorial it will closely you may wonder when this underscores the because in the cute library itself this muscle is just called but it turns out X X is a key in Python so they could not name their method exit because unlike the proles 6 developers the the Python developed and said no it's more important To make implementing a Python parser easy where the April 6 developers say not let's torture that developed it for the sake of the users and they really do so I can show you another middle of emotions of it sometimes some serious the very 1st
and follow program using python skewed findings but uh in quit meaning that Mac by this idea really sure methods but
so with this and I want to go back to my goal for today I think
it's I think I've reached my goal and there should be nothing standing in your way through if you want to try process 6 so I can only tell you try it but if you can find this coat on get up you can find the slides online containing all the examples are shown you and they're all completes and they can also run them so which questions are left on this so this is the whole of the rest of the if you the of the and have highest of the of the of the of the of the of the of and how we could use the the and I not yet I have thought about some these gotchas to the documentation and I will but also in thinking about how to remove the problem altogether because most of them are just because of the rate in Lempel 5 is implemented right now but it was a very many you can limitation I think they're just a 1st thing I found that works really Jonathan has some ideas have competition prove it looks like that it the I will say that you know it will not be the yeah gate which other questions on the left but not right now New confinement around here in this area problem throughout the day and just approach me or asked me on IRC channel and again thank you very much for listening and a big thank you to all the people involved in writing people call 6 and profile for that and they're very nice people that helped me under siege and writing my very 1st 6 software thank you bit if
Server
Subtraktion
Bit
Quader
Klasse <Mathematik>
Formale Sprache
Befehl <Informatik>
Wrapper <Programmierung>
Code
Chatbot
Methodenbank
Informationsmodellierung
Hook <Programmierung>
Gruppe <Mathematik>
Wrapper <Programmierung>
Vererbungshierarchie
Modul
Leistung <Physik>
Softwaretest
Kraftfahrzeugmechatroniker
Lineares Funktional
Konstruktor <Informatik>
Parametersystem
Nichtlinearer Operator
Multifunktion
Befehl <Informatik>
Antwortfunktion
Vererbungshierarchie
Profil <Aerodynamik>
Systemaufruf
Symboltabelle
Schlussregel
Parser
Sichtenkonzept
Modul
Quick-Sort
Objekt <Kategorie>
Polstelle
Modallogik
Last
Geschlecht <Mathematik>
Festspeicher
Basisvektor
Mereologie
Chatbot
Message-Passing
Demo <Programm>
Prozess <Physik>
Schreiben <Datenverarbeitung>
Parser
Kartesische Koordinaten
Euler-Winkel
Template
Skalarfeld
Netzwerktopologie
Metadaten
Gamecontroller
Minimum
Parallele Schnittstelle
Kraftfahrzeugmechatroniker
Parametersystem
Namensraum
Sichtenkonzept
Systemaufruf
Profil <Aerodynamik>
Quellcode
Elektronische Unterschrift
Rechenschieber
Diskrete-Elemente-Methode
Wurzel <Mathematik>
Rechter Winkel
Projektive Ebene
Information
Zeichenkette
Fehlermeldung
Objekt <Kategorie>
Multiplikation
Gerichteter Graph
Gruppenoperation
Klasse <Mathematik>
Implementierung
Zahlenbereich
Informationsmodellierung
Lesezeichen <Internet>
Unterring
Demo <Programm>
Meta-Tag
Modul
Antwortfunktion
Namensraum
Konfigurationsraum
Indexberechnung
Mailing-Liste
Elektronische Publikation
Parser
Sichtenkonzept
Grundrechenart
Datenfluss
Modul
Objekt <Kategorie>
Regulärer Ausdruck
Last
Gamecontroller
Attributierte Grammatik
Textbaustein
Bit
Prozess <Physik>
Gemeinsamer Speicher
Minimierung
Formale Sprache
Formale Grammatik
Kartesische Koordinaten
Übergang
Bildschirmfenster
Abstrakter Syntaxbaum
Speicherabzug
Kartesische Koordinaten
Schnelltaste
Statistik
Namensraum
Profil <Aerodynamik>
Systemaufruf
Digitalfilter
Quellcode
Variable
Diskrete-Elemente-Methode
Rechter Winkel
Anpassung <Mathematik>
Information
Charakteristisches Polynom
Overhead <Kommunikationstechnik>
Ordnung <Mathematik>
Schlüsselverwaltung
Aggregatzustand
Multiplikation
Klasse <Mathematik>
Term
Code
Hydrostatik
Open Source
Message-Passing
Informationsmodellierung
Bildschirmmaske
Reelle Zahl
Endogene Variable
Widget
Vererbungshierarchie
Programmbibliothek
Äußere Algebra eines Moduls
Inverser Limes
Optimierung
Softwareentwickler
Maßerweiterung
Ereignishorizont
Demo <Programm>
Modul
Benutzeroberfläche
Graph
Spider <Programm>
Just-in-Time-Compiler
Vererbungshierarchie
Default
Parser
Modul
Objekt <Kategorie>
System F
Mereologie
Arithmetisches Mittel
BORIS <Programm>
Einheit <Mathematik>
Optimierung
Modul
Rechenschieber
Prozess <Physik>
Verknüpfungsglied
Flächeninhalt
Software
Quarkconfinement
Profil <Aerodynamik>
Inverser Limes
Bitrate
Modul

Metadaten

Formale Metadaten

Titel Leapfrogging the bootstrap
Untertitel Bringing whole module ecosystem to Perl 6
Alternativer Titel Perl - Dules Ecosystem Perl 6
Serientitel FOSDEM 2015
Autor Seifert, Stefan
Lizenz CC-Namensnennung 2.0 Belgien:
Sie dürfen das Werk bzw. den Inhalt zu jedem legalen Zweck nutzen, verändern und in unveränderter oder veränderter Form vervielfältigen, verbreiten und öffentlich zugänglich machen, sofern Sie den Namen des Autors/Rechteinhabers in der von ihm festgelegten Weise nennen.
DOI 10.5446/34462
Herausgeber FOSDEM VZW
Erscheinungsjahr 2016
Sprache Englisch
Produktionsjahr 2015

Inhaltliche Metadaten

Fachgebiet Informatik

Ähnliche Filme

Loading...
Feedback