diff --git a/.gitmodules b/.gitmodules index af8c2d11..79209740 100644 --- a/.gitmodules +++ b/.gitmodules @@ -546,3 +546,6 @@ [submodule "vendor/grammars/Racket"] path = vendor/grammars/Racket url = https://github.com/soegaard/racket-highlight-for-github +[submodule "vendor/grammars/turtle.tmbundle"] + path = vendor/grammars/turtle.tmbundle + url = https://github.com/peta/turtle.tmbundle diff --git a/grammars.yml b/grammars.yml index bb06d939..c85b2de6 100644 --- a/grammars.yml +++ b/grammars.yml @@ -452,6 +452,9 @@ vendor/grammars/thrift.tmbundle: - source.thrift vendor/grammars/toml.tmbundle: - source.toml +vendor/grammars/turtle.tmbundle: +- source.sparql +- source.turtle vendor/grammars/verilog.tmbundle: - source.verilog vendor/grammars/x86-assembly-textmate-bundle: diff --git a/lib/linguist/heuristics.rb b/lib/linguist/heuristics.rb index 5e603f23..392ab7f5 100644 --- a/lib/linguist/heuristics.rb +++ b/lib/linguist/heuristics.rb @@ -69,6 +69,14 @@ module Linguist end end + disambiguate "C#", "Smalltalk" do |data| + if /![\w\s]+methodsFor: /.match(data) + Language["Smalltalk"] + elsif /^\s*namespace\s*[\w\.]+\s*{/.match(data) || /^\s*\/\//.match(data) + Language["C#"] + end + end + disambiguate "Objective-C", "C++", "C" do |data| if (/^[ \t]*@(interface|class|protocol|property|end|synchronised|selector|implementation)\b/.match(data)) Language["Objective-C"] @@ -104,6 +112,15 @@ module Linguist end end + disambiguate "GAP", "Scilab" do |data| + if (data.include?("gap> ")) + Language["GAP"] + # Heads up - we don't usually write heuristics like this (with no regex match) + else + Language["Scilab"] + end + end + disambiguate "Common Lisp", "OpenCL", "Cool" do |data| if data.include?("(defun ") Language["Common Lisp"] diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index be4de69d..4a011e87 100644 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -504,10 +504,10 @@ Clojure: - .cl2 - .cljc - .cljs + - .cljs.hl - .cljscm - .cljx - .hic - - .hl filenames: - riemann.config @@ -951,11 +951,13 @@ GAMS: GAP: type: programming + lexer: GAP extensions: - .g - .gap - .gd - .gi + - .tst tm_scope: none ace_mode: text @@ -1172,6 +1174,7 @@ HTML: extensions: - .html - .htm + - .html.hl - .st - .xht - .xhtml @@ -1197,7 +1200,7 @@ HTML+ERB: - erb extensions: - .erb - - .deface + - .erb.deface ace_mode: html_ruby HTML+PHP: @@ -1228,7 +1231,7 @@ Haml: type: markup extensions: - .haml - - .deface + - .haml.deface ace_mode: haml Handlebars: @@ -2054,7 +2057,7 @@ OpenSCAD: extensions: - .scad tm_scope: none - ace_mode: text + ace_mode: scad Org: type: prose @@ -2211,6 +2214,8 @@ Perl6: - .pm - .pm6 - .t + filenames: + - Rexfile interpreters: - perl6 tm_scope: none @@ -2230,6 +2235,8 @@ Pike: extensions: - .pike - .pmod + interpreters: + - pike ace_mode: text Pod: @@ -2612,6 +2619,14 @@ SCSS: extensions: - .scss +SPARQL: + type: data + tm_scope: source.sparql + ace_mode: text + extensions: + - .sparql + - .rq + SQF: type: programming color: "#FFCB1F" @@ -2639,14 +2654,15 @@ STON: group: Smalltalk extensions: - .ston - tm_scope: source.json - ace_mode: lisp + tm_scope: source.smalltalk + ace_mode: text Sage: type: programming group: Python extensions: - .sage + - .sagews tm_scope: source.python ace_mode: python @@ -2968,6 +2984,13 @@ Turing: tm_scope: none ace_mode: text +Turtle: + type: data + extensions: + - .ttl + tm_scope: source.turtle + ace_mode: text + Twig: type: markup group: PHP @@ -3082,6 +3105,14 @@ Volt: tm_scope: source.d ace_mode: d +Web Ontology Language: + type: markup + color: "#3994bc" + extensions: + - .owl + tm_scope: text.xml + ace_mode: xml + WebIDL: type: programming extensions: @@ -3118,6 +3149,7 @@ XML: - .dll.config - .filters - .fsproj + - .fxml - .glade - .grxml - .ivy diff --git a/lib/linguist/version.rb b/lib/linguist/version.rb index 3f330f79..73b6c63a 100644 --- a/lib/linguist/version.rb +++ b/lib/linguist/version.rb @@ -1,3 +1,3 @@ module Linguist - VERSION = "4.2.6" + VERSION = "4.2.7" end diff --git a/samples/GAP/bugfix.tst b/samples/GAP/bugfix.tst new file mode 100644 index 00000000..be4bd975 --- /dev/null +++ b/samples/GAP/bugfix.tst @@ -0,0 +1,161 @@ +gap> START_TEST("Test for various former bugs"); + + +gap> # The following used to trigger an error starting with: +gap> # "SolutionMat: matrix and vector incompatible called from" +gap> K:=AbelianPcpGroup([3,3,3]);; +gap> A:=Subgroup(K,[K.1]);; +gap> cr:=CRRecordBySubgroup(K,A);; +gap> ExtensionsCR(cr);; + + +# Comparing homomorphisms used to be broken +gap> K:=AbelianPcpGroup(1,[3]);; +gap> hom1:=GroupHomomorphismByImages(K,K,[K.1],[K.1]);; +gap> hom2:=GroupHomomorphismByImages(K,K,[K.1^2],[K.1^2]);; +gap> hom1=hom2; +true +gap> hom1=IdentityMapping(K); +true +gap> hom2=IdentityMapping(K); +true + + +gap> # The following incorrectly triggered an error at some point +gap> IsTorsionFree(ExamplesOfSomePcpGroups(5)); +true + + +gap> # Verify IsGeneratorsOfMagmaWithInverses warnings are silenced +gap> IsGeneratorsOfMagmaWithInverses(GeneratorsOfGroup(ExamplesOfSomePcpGroups(5))); +true + + +gap> # Check for a bug reported 2012-01-19 by Robert Morse +gap> g := PcGroupToPcpGroup(SmallGroup(48,1)); +Pcp-group with orders [ 2, 2, 2, 2, 3 ] +gap> # The next two commands used to trigger errors +gap> NonAbelianTensorSquare(Centre(g)); +Pcp-group with orders [ 8 ] +gap> NonAbelianExteriorSquare(Centre(g)); +Pcp-group with orders [ ] + + +gap> # Check for a bug reported 2012-01-19 by Robert Morse +gap> F := FreeGroup("x","y"); + +gap> x := F.1;; y := F.2;; +gap> G := F/[x^2/y^24, y^24, y^x/y^23]; + +gap> iso := IsomorphismPcGroup(G); +[ x, y ] -> [ f1, f2*f5 ] +gap> iso1 := IsomorphismPcpGroup(Image(iso)); +[ f1, f2, f3, f4, f5 ] -> [ g1, g2, g3, g4, g5 ] +gap> G := Image(iso*iso1); +Pcp-group with orders [ 2, 2, 2, 2, 3 ] +gap> # The next command used to trigger an error +gap> NonAbelianTensorSquare(Image(iso*iso1)); +Pcp-group with orders [ 2, 2, 3, 2, 2, 2, 2 ] + + +gap> # The problem with the previous example is/was that Igs(G) +gap> # is set to a non-standard value: +gap> Igs(G); +[ g1, g2*g5, g3*g4*g5^2, g4*g5, g5 ] +gap> # Unfortunately, it seems that a lot of code that +gap> # really should be using Ngs or Cgs is using Igs incorrectly. +gap> # For example, direct products could return *invalid* embeddings: +gap> D := DirectProduct(G, G); +Pcp-group with orders [ 2, 2, 2, 2, 3, 2, 2, 2, 2, 3 ] +gap> hom:=Embedding(D,1);; +gap> mapi:=MappingGeneratorsImages(hom);; +gap> GroupHomomorphismByImages(Source(hom),Range(hom),mapi[1],mapi[2]) <> fail; +true +gap> hom:=Projection(D,1);; +gap> mapi:=MappingGeneratorsImages(hom);; +gap> GroupHomomorphismByImages(Source(hom),Range(hom),mapi[1],mapi[2]) <> fail; +true + + +gap> # Check for bug computing Schur extension of infinite cyclic groups, +gap> # found by Max Horn 2012-05-25 +gap> G:=AbelianPcpGroup(1,[0]); +Pcp-group with orders [ 0 ] +gap> # The next command used to trigger an error +gap> SchurExtension(G); +Pcp-group with orders [ 0 ] + + +gap> # Check for bug computing Schur extensions of subgroups, found by MH 2012-05-25. +gap> G:=HeisenbergPcpGroup(2); +Pcp-group with orders [ 0, 0, 0, 0, 0 ] +gap> H:=Subgroup(G,[G.2^3*G.3^2, G.1^9]); +Pcp-group with orders [ 0, 0, 0 ] +gap> # The next command used to trigger an error +gap> SchurExtension(H); +Pcp-group with orders [ 0, 0, 0, 0, 0, 0 ] + + +gap> # Check for bug computing Schur extensions of subgroups, found by MH 2012-05-25. +gap> G:=HeisenbergPcpGroup(2); +Pcp-group with orders [ 0, 0, 0, 0, 0 ] +gap> H:=Subgroup(G,[G.1, G.2]); +Pcp-group with orders [ 0, 0 ] +gap> # The next command used to trigger an error +gap> SchurExtension(H); +Pcp-group with orders [ 0, 0, 0 ] + + +gap> # Check for bug computing normalizer of two subgroups, found by MH 2012-05-30. +gap> # The problem was caused by incorrect resp. overly restrictive use of Parent(). +gap> G:=HeisenbergPcpGroup(2); +Pcp-group with orders [ 0, 0, 0, 0, 0 ] +gap> A:=Subgroup(Subgroup(G,[G.2,G.3,G.4,G.5]), [G.3]); +Pcp-group with orders [ 0 ] +gap> B:=Subgroup(Subgroup(G,[G.1,G.4,G.5]), [G.4]); +Pcp-group with orders [ 0 ] +gap> Normalizer(A,B); +Pcp-group with orders [ 0 ] +gap> # The following used to trigger the error "arguments must have a common parent group" +gap> Normalizer(B,A); +Pcp-group with orders [ 0 ] + + +gap> # In polycyclic 2.9 and 2.10, the code for 2-cohomology computations was broken. +gap> G := UnitriangularPcpGroup(3,0); +Pcp-group with orders [ 0, 0, 0 ] +gap> mats := G!.mats; +[ [ [ 1, 1, 0 ], [ 0, 1, 0 ], [ 0, 0, 1 ] ], + [ [ 1, 0, 0 ], [ 0, 1, 1 ], [ 0, 0, 1 ] ], + [ [ 1, 0, 1 ], [ 0, 1, 0 ], [ 0, 0, 1 ] ] ] +gap> C := CRRecordByMats(G,mats);; +gap> cc := TwoCohomologyCR(C);; +gap> cc.factor.rels; +[ 2, 0, 0 ] +gap> c := cc.factor.prei[2]; +[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, -1, 1 ] +gap> cc.gcb; +[ [ 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ], + [ 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0 ], + [ 0, -1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, -1 ], + [ -1, 0, 1, 1, 0, 0, 0, -1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0 ], + [ 0, -1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 1 ] ] +gap> cc.gcc; +[ [ 1, 0, 0, 0, 0, -2, -1, 0, 1, 1, -1, -1, 0, 0, 0, 0, 0, 0 ], + [ 0, 1, 0, 0, -1, -1, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0 ], + [ 0, 0, 1, 0, 0, -2, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0 ], + [ 0, 0, 0, 1, 0, 0, -1, -1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0 ], + [ 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], + [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, -1, 1 ], + [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, -1 ] ] + + +gap> # LowerCentralSeriesOfGroup for non-nilpotent pcp-groups used to trigger +gap> # an infinite recursion +gap> G := PcGroupToPcpGroup(SmallGroup(6,1)); +Pcp-group with orders [ 2, 3 ] +gap> LowerCentralSeriesOfGroup(G); +[ Pcp-group with orders [ 2, 3 ], Pcp-group with orders [ 3 ] ] + + +gap> STOP_TEST( "bugfix.tst", 10000000); diff --git a/samples/GAP/factor.tst b/samples/GAP/factor.tst new file mode 100644 index 00000000..115fe921 --- /dev/null +++ b/samples/GAP/factor.tst @@ -0,0 +1,21 @@ +gap> START_TEST("Test of factor groups and natural homomorphisms"); + +gap> G:=HeisenbergPcpGroup(2); +Pcp-group with orders [ 0, 0, 0, 0, 0 ] + +gap> H:=Subgroup(G,[G.2,G.3,G.4,G.5]); +gap> K:=G/H; +gap> NaturalHomomorphism(K); + +gap> A:=Subgroup(H, [G.3]); +Pcp-group with orders [ 0 ] +gap> B:=Subgroup(Subgroup(G,[G.1,G.4,G.5]), [G.4]); +Pcp-group with orders [ 0 ] +gap> Normalizer(A,B); +Pcp-group with orders [ 0 ] +gap> # The following used to trigger the error "arguments must have a common parent group" +gap> Normalizer(B,A); +Pcp-group with orders [ 0 ] + + +gap> STOP_TEST( "factor.tst", 10000000); diff --git a/samples/HTML/index.html.hl b/samples/HTML/index.html.hl new file mode 100644 index 00000000..65491957 --- /dev/null +++ b/samples/HTML/index.html.hl @@ -0,0 +1,328 @@ + + + + + + + + +
+

Example 1

+ + + + + +
+ + +
+ +

~{x}

+
+
+
+
+ + +
+

Example 2

+ + + + + +
+ + +
+ +

~{x}

+
+
+
+
+ + +
+

Example 3

+ + + + + +
+ + + +
+ +

~{x}

+
+
+
+
+ + +
+

Example 4

+ + + + + +
+ + +
+
+
+ + +
+

Example 5

+ + + + + +
+ + +
+
+
+ + +
+

Example 6

+ + + + + +
+ + +
+
+ +

~{x}

+
+
+
+
+
+ + +
+

Example 7

+ + + + + +
+ + +
+
+ +

~{x}

+
+
+
+
+
+ + +
+

Example 8

+ + + + + +
+ + +
+
+ +

~{x}

+
+
+
+
+
+ + +
+

Example 9

+ + + + + +
+ + +
+
+ + +
+

Example 10

+ + + + + +
+ + + +
+
+ + diff --git a/samples/Pike/shebang.pike b/samples/Pike/shebang.pike new file mode 100644 index 00000000..31bf7e96 --- /dev/null +++ b/samples/Pike/shebang.pike @@ -0,0 +1,6 @@ +#!/usr/bin/env pike + +int main(int argc, array argv) { + return 0; +} + diff --git a/samples/SPARQL/foaf.sparql b/samples/SPARQL/foaf.sparql new file mode 100644 index 00000000..699360c7 --- /dev/null +++ b/samples/SPARQL/foaf.sparql @@ -0,0 +1,7 @@ +PREFIX foaf: +SELECT ?name ?email +WHERE { + ?person a foaf:Person. + ?person foaf:name ?name. + ?person foaf:mbox ?email. +} diff --git a/samples/SPARQL/string-matching.sparql b/samples/SPARQL/string-matching.sparql new file mode 100644 index 00000000..424ca987 --- /dev/null +++ b/samples/SPARQL/string-matching.sparql @@ -0,0 +1,40 @@ +PREFIX owl: +PREFIX rdf: +PREFIX skos: + +SELECT DISTINCT ?s ?label +WHERE { + SERVICE + { + SELECT DISTINCT ?s ?label ?plabel ?alabel ?hlabel (GROUP_CONCAT(DISTINCT STR(?type)) as ?types) + WHERE { + GRAPH + { + ?s rdf:type + { + ?s rdf:type ?type . + ?s ?prop ?match . + FILTER ( + strstarts(lcase(str(?match)), "test") && !(?match != ?label && strstarts(lcase(str(?label)), "test")) + ) + OPTIONAL { + ?s skos:prefLabel ?label . + FILTER (langMatches(lang(?label), "en")) + } + OPTIONAL { # in case previous OPTIONAL block gives no labels + ?s ?prop ?match . + ?s skos:prefLabel ?label . + FILTER (langMatches(lang(?label), lang(?match))) } + } + FILTER NOT EXISTS { ?s owl:deprecated true } + } + BIND(IF(?prop = skos:prefLabel && ?match != ?label, ?match, "") as ?plabel) + BIND(IF(?prop = skos:altLabel, ?match, "") as ?alabel) + BIND(IF(?prop = skos:hiddenLabel, ?match, "") as ?hlabel) + VALUES (?prop) { (skos:prefLabel) (skos:altLabel) (skos:hiddenLabel) } + } + GROUP BY ?match ?s ?label ?plabel ?alabel ?hlabel ?prop + ORDER BY lcase(str(?match)) lang(?match) + LIMIT 10 + } +} diff --git a/samples/Sage/polinomios.sagews b/samples/Sage/polinomios.sagews new file mode 100644 index 00000000..4edb2234 --- /dev/null +++ b/samples/Sage/polinomios.sagews @@ -0,0 +1,136 @@ +# -*- coding: utf-8 -*- +# +# Funciones en Python/Sage para el trabajo con polinomios con una +# incógnita (x). +# +# Copyright (C) 2014-2015, David Abián +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the Free +# Software Foundation, either version 3 of the License, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +# more details. +# +# You should have received a copy of the GNU General Public License along with +# this program. If not, see . + +def pols (grado=-1, K=GF(2), mostrar=False): + """Devuelve la lista de polinomios constantes y no constantes de + coeficientes mónicos y grado igual o menor que el especificado. + Si el grado indicado no es válido, devuelve una lista vacía. + """ + lpols = [] + if not grado.is_integer(): + grado = grado.round() + if grado >= 0: + var('x') + xs = vector([(x^i) for i in range(grado+1)]) + V = VectorSpace(K,grado+1) + lpols = [cs*xs for cs in V] + if mostrar: + for pol in lpols: + print pol + return lpols + +def polsNoCtes (grado=-1, K=GF(2), mostrar=False): + """Devuelve la lista de polinomios no constantes de coeficientes mónicos y + grado igual o menor que el especificado. + Si el grado indicado no es válido, devuelve una lista vacía. + """ + lpols = [] + if not grado.is_integer(): + grado = grado.round() + if grado >= 0: + var('x') + xs = vector([(x^i) for i in range(grado+1)]) + for cs in K^(grado+1): + if cs[:grado] != vector(grado*[0]): # no constantes + lpols += [cs*xs] + if mostrar: + for pol in lpols: + print pol + return lpols + +def polsMismoGrado (grado=-1, K=GF(2), mostrar=False): + """Devuelve la lista de polinomios de coeficientes mónicos del grado + especificado. + Si el grado indicado no es válido, devuelve una lista vacía. + """ + lpols = [] + if not grado.is_integer(): + grado = grado.round() + if grado >= 0: + var('x') + xs = vector([(x^(grado-i)) for i in [0..grado]]) + for cs in K^(grado+1): + if cs[0] != 0: # polinomios del mismo grado + lpols += [cs*xs] + if mostrar: + for pol in lpols: + print pol + return lpols + +def excluirReducibles (lpols=[], mostrar=False): + """Filtra una lista dada de polinomios de coeficientes mónicos y devuelve + aquellos irreducibles. + """ + var('x') + irreds = [] + for p in lpols: + fp = (p.factor_list()) + if len(fp) == 1 and fp[0][1] == 1: + irreds += [p] + if mostrar: + for pol in irreds: + print pol + return irreds + +def vecPol (vec=random_vector(GF(2),0)): + """Transforma los coeficientes dados en forma de vector en el polinomio + que representan. + + Por ejemplo, con vecPol(vector([1,0,3,1])) se obtiene x³ + 3*x + 1. + + Para la función opuesta, véase polVec(). + """ + var('x') + xs = vector([x^(len(vec)-1-i) for i in range(len(vec))]) + return vec*xs + +def polVec (p=None): + """Devuelve el vector de coeficientes del polinomio dado que acompañan a la + incógnita x, de mayor a menor grado. + + Por ejemplo, con polVec(x^3 + 3*x + 1) se obtiene el vector (1, 0, 3, 1). + + Para la función opuesta, véase vecPol(). + """ + cs = [] + if p != None: + var('x') + p(x) = p + for i in [0..p(x).degree(x)]: + cs.append(p(x).coefficient(x,i)) + cs = list(reversed(cs)) + return vector(cs) + +def completar2 (p=0): + """Aplica el método de completar cuadrados en parábolas al polinomio dado de + grado 2 y lo devuelve en su nueva forma. + + Si el polinomio dado no es válido, devuelve 0. + + Por ejemplo, con complCuad(3*x^2 + 12*x + 5) se obtiene 3*(x + 2)^2 - 7. + """ + var('x') + p(x) = p.expand() + if p(x).degree(x) != 2: + p(x) = 0 + else: + cs = polVec(p(x)) + p(x) = cs[0]*(x+(cs[1]/(2*cs[0])))^2+(4*cs[0]*cs[2]-cs[1]^2)/(4*cs[0]) + return p(x) diff --git a/samples/Turtle/gnd-record.ttl b/samples/Turtle/gnd-record.ttl new file mode 100644 index 00000000..ef1d2c35 --- /dev/null +++ b/samples/Turtle/gnd-record.ttl @@ -0,0 +1,183 @@ +@prefix foaf: . +@prefix owl: . +@prefix gndo: . +@prefix xsd: . + + + a ; + foaf:page ; + owl:sameAs , , ; + gndo:gndIdentifier "118514768" ; + gndo:oldAuthorityNumber "(DE-588)1022091077", "(DE-588a)118514768", "(DE-588a)141399074", "(DE-588a)139089691", "(DE-588a)141300248", "(DE-588a)136949541", "(DE-588a)134336232", "(DE-588a)12794544X", "(DE-588a)12736630X", "(DE-588a)12722811X", "(DE-588a)127228098", "(DE-588a)127228101" ; + gndo:variantNameForThePerson "Brêcht, Becton", "Brecht, Bert", "Brecht, Bertolʹ", "Brecht, Berthold", "Brecht, Bertholt", "Brecht, Bertold", "Brecht, B.", "Brecht, Eugen Berthold Friedrich", "Brecht, ...", "Brecht-Eisler, ...", "Becht, Bertolt", "Beituo'erte-Bulaixite", "Berchito, B.", "Brechtas, B.", "Brechts, Bertolts", "Brehd, Berd", "Breht, Bertolt", "Brehts, Bertolts", "Breḳhṭ, Bārṭolṭ", "Brekt, Berṭolṭ", "Brekṭ, Berṭōlṭ", "Breḳṭ, Berṭôlṭ", "Breśṭ, Berṭalṭa", "Breṣṭa, Barṭolṭa", "Brišt, Bartūlt", "Brišt, Birtūld", "Brišt, Birtult", "Buchito, Berutorutu", "Bulaixite, Beituo'erte", "Bulaixite, ...", "Burehito, Berutoruto", "Burehito, ...", "B. B.", "Larsen, Berthold", "Mprecht, Mpertolt", "Mprecht, ...", "Pulaihsit'ê, Peit'oĉrht'ê", "Pulaihsit'ê, ...", "Pŭrehit'ŭ, Peŏt'olt'ŭ", "Bŭrehit'ŭ, Beŏt'olt'ŭ", "برشت، برتولد", "브레히트, 베르톨트", "ברכט, ברטולט", "贝·布莱希特", "布莱希特, 贝", "ブレヒト, ベルトルト" ; + gndo:variantNameEntityForThePerson [ + gndo:forename "Becton" ; + gndo:surname "Brêcht" + ], [ + gndo:forename "Bert" ; + gndo:surname "Brecht" + ], [ + gndo:forename "Bertolʹ" ; + gndo:surname "Brecht" + ], [ + gndo:forename "Berthold" ; + gndo:surname "Brecht" + ], [ + gndo:forename "Bertholt" ; + gndo:surname "Brecht" + ], [ + gndo:forename "Bertold" ; + gndo:surname "Brecht" + ], [ + gndo:forename "B." ; + gndo:surname "Brecht" + ], [ + gndo:forename "Eugen Berthold Friedrich" ; + gndo:surname "Brecht" + ], [ + gndo:forename "..." ; + gndo:surname "Brecht" + ], [ + gndo:forename "..." ; + gndo:surname "Brecht-Eisler" + ], [ + gndo:forename "Bertolt" ; + gndo:surname "Becht" + ], [ gndo:personalName "Beituo'erte-Bulaixite" ], [ + gndo:forename "B." ; + gndo:surname "Berchito" + ], [ + gndo:forename "B." ; + gndo:surname "Brechtas" + ], [ + gndo:forename "Bertolts" ; + gndo:surname "Brechts" + ], [ + gndo:forename "Berd" ; + gndo:surname "Brehd" + ], [ + gndo:forename "Bertolt" ; + gndo:surname "Breht" + ], [ + gndo:forename "Bertolts" ; + gndo:surname "Brehts" + ], [ + gndo:forename "Bārṭolṭ" ; + gndo:surname "Breḳhṭ" + ], [ + gndo:forename "Berṭolṭ" ; + gndo:surname "Brekt" + ], [ + gndo:forename "Berṭōlṭ" ; + gndo:surname "Brekṭ" + ], [ + gndo:forename "Berṭôlṭ" ; + gndo:surname "Breḳṭ" + ], [ + gndo:forename "Berṭalṭa" ; + gndo:surname "Breśṭ" + ], [ + gndo:forename "Barṭolṭa" ; + gndo:surname "Breṣṭa" + ], [ + gndo:forename "Bartūlt" ; + gndo:surname "Brišt" + ], [ + gndo:forename "Birtūld" ; + gndo:surname "Brišt" + ], [ + gndo:forename "Birtult" ; + gndo:surname "Brišt" + ], [ + gndo:forename "Berutorutu" ; + gndo:surname "Buchito" + ], [ + gndo:forename "Beituo'erte" ; + gndo:surname "Bulaixite" + ], [ + gndo:forename "..." ; + gndo:surname "Bulaixite" + ], [ + gndo:forename "Berutoruto" ; + gndo:surname "Burehito" + ], [ + gndo:forename "..." ; + gndo:surname "Burehito" + ], [ gndo:personalName "B. B." ], [ + gndo:forename "Berthold" ; + gndo:surname "Larsen" + ], [ + gndo:forename "Mpertolt" ; + gndo:surname "Mprecht" + ], [ + gndo:forename "..." ; + gndo:surname "Mprecht" + ], [ + gndo:forename "Peit'oĉrht'ê" ; + gndo:surname "Pulaihsit'ê" + ], [ + gndo:forename "..." ; + gndo:surname "Pulaihsit'ê" + ], [ + gndo:forename "Peŏt'olt'ŭ" ; + gndo:surname "Pŭrehit'ŭ" + ], [ + gndo:forename "Beŏt'olt'ŭ" ; + gndo:surname "Bŭrehit'ŭ" + ], [ gndo:personalName "برشت، برتولد" ], [ + gndo:forename "베르톨트" ; + gndo:surname "브레히트" + ], [ + gndo:forename "ברטולט" ; + gndo:surname "ברכט" + ], [ gndo:personalName "贝·布莱希特" ], [ + gndo:forename "贝" ; + gndo:surname "布莱希特" + ], [ + gndo:forename "ベルトルト" ; + gndo:surname "ブレヒト" + ] ; + gndo:preferredNameForThePerson "Brecht, Bertolt" ; + gndo:preferredNameEntityForThePerson [ + gndo:forename "Bertolt" ; + gndo:surname "Brecht" + ] ; + gndo:familialRelationship , , , , , , , , , , , , , , ; + gndo:professionOrOccupation , , , , , , ; + gndo:playedInstrument ; + gndo:gndSubjectCategory , , ; + gndo:geographicAreaCode ; + gndo:languageCode ; + gndo:placeOfBirth ; + gndo:placeOfDeath ; + gndo:placeOfExile , ; + gndo:gender ; + gndo:dateOfBirth "1898-02-10"^^xsd:date ; + gndo:dateOfDeath "1956-08-14"^^xsd:date . + + gndo:preferredNameForThePerson "Brecht, Berthold Friedrich" . + gndo:preferredNameForThePerson "Banholzer, Paula" . + gndo:preferredNameForThePerson "Neher, Carola" . + gndo:preferredNameForThePerson "Banholzer, Frank" . + gndo:preferredNameForThePerson "Berlau, Ruth" . + gndo:preferredNameForThePerson "Steffin, Margarete" . + gndo:preferredNameForThePerson "Zoff, Marianne" . + gndo:preferredNameForThePerson "Weigel, Helene" . + gndo:preferredNameForThePerson "Reichel, Käthe" . + gndo:preferredNameForThePerson "Hiob, Hanne" . + gndo:preferredNameForThePerson "Brecht, Stefan" . + gndo:preferredNameForThePerson "Brecht-Schall, Barbara" . + gndo:preferredNameForThePerson "Schall, Ekkehard" . + gndo:preferredNameForThePerson "Brezing, Joseph Friedrich" . + gndo:preferredNameForThePerson "Brezing, Friederike" . + gndo:preferredNameForTheSubjectHeading "Theaterregisseur" . + gndo:preferredNameForTheSubjectHeading "Dramatiker" . + gndo:preferredNameForTheSubjectHeading "Schauspieler" . + gndo:preferredNameForTheSubjectHeading "Lyriker" . + gndo:preferredNameForTheSubjectHeading "Schriftsteller" . + gndo:preferredNameForTheSubjectHeading "Regisseur" . + gndo:preferredNameForTheSubjectHeading "Drehbuchautor" . + gndo:preferredNameForThePlaceOrGeographicName "Augsburg" . + gndo:preferredNameForThePlaceOrGeographicName "Berlin" . + gndo:preferredNameForThePlaceOrGeographicName "Dänemark" . + gndo:preferredNameForThePlaceOrGeographicName "Schweden" . \ No newline at end of file diff --git a/samples/Turtle/rdf-syntax-grammar.ttl b/samples/Turtle/rdf-syntax-grammar.ttl new file mode 100644 index 00000000..edcd4db2 --- /dev/null +++ b/samples/Turtle/rdf-syntax-grammar.ttl @@ -0,0 +1,10 @@ +@prefix rdf: . +@prefix dc: . +@prefix ex: . + + + dc:title "RDF/XML Syntax Specification (Revised)" ; + ex:editor [ + ex:fullname "Dave Beckett"; + ex:homePage + ] . \ No newline at end of file diff --git a/samples/Web Ontology Language/sample.owl b/samples/Web Ontology Language/sample.owl new file mode 100644 index 00000000..612186db --- /dev/null +++ b/samples/Web Ontology Language/sample.owl @@ -0,0 +1,6858 @@ + + + + + + + +]> + + + + + v.1.4. Added Food class (used in domain/range of hasIngredient), Added several hasCountryOfOrigin restrictions on pizzas, Made hasTopping invers functional + version 1.5 + v.1.5. Removed protege.owl import and references. Made ontology URI date-independent + An example ontology that contains all constructs required for the various versions of the Pizza Tutorial run by Manchester University (see http://www.co-ode.org/resources/tutorials/) + + + + + + + + + + + + + Americana + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + AmericanaPicante + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeAnchovies + + + + + + + + + + + CoberturaDeArtichoke + + + + + + + + + + + + + + + + + CoberturaDeAspargos + + + + + + + + + + + + + + + + + Cajun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeCajun + + + + + + + + + + + + + + + + + CoberturaDeCaper + + + + + + + + + + + + + + + + + Capricciosa + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Caprina + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeQueijo + + + + + + + + + + + Any pizza that has at least 1 cheese topping. + PizzaComQueijo + + + + + + + + + + + + + + + + + + + CoberturaDeQueijoComVegetais + This class will be inconsistent. This is because we have given it 2 disjoint parents, which means it could never have any members (as nothing can simultaneously be a CheeseTopping and a VegetableTopping). NB Called ProbeInconsistentTopping in the ProtegeOWL Tutorial. + + + + + + + + + + + + + + CoberturaDeFrango + + + + + + + + + + + + + + + + + Pais + A class that is equivalent to the set of individuals that are described in the enumeration - ie Countries can only be either America, England, France, Germany or Italy and nothing else. Note that these individuals have been asserted to be allDifferent from each other. + + + + + + + + + + + + + + + + + + + + + + + + BaseEspessa + + + + + + + + + + + + + + + + + Fiorentina + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDePeixe + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaQuatroQueijos + + + + + + + + + + + + + + + + + QuatroQueijos + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeFrutas + + + + + + + + + + + FrutosDoMar + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeAlho + + + + + + + + + + + + + + + + + Giardiniera + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeQueijoDeCabra + + + + + + + + + + + + + + + + + CoberturaDeGorgonzola + + + + + + + + + + + + + + + + + CoberturaDePimentaoVerde + + + + + + + + + + + CoberturaDePresunto + + + + + + + + + + + CoberturaDeErvas + + + + + + + + + + + Picante + + + + + + + + + + + CoberturaDePimentaoVerdePicante + + + + + + + + + + + + + + + + + CoberturaDeBifePicante + + + + + + + + + + + + + + + + + A class to demonstrate mistakes made with setting a property domain. The property hasTopping has a domain of Pizza. This means that the reasoner can infer that all individuals using the hasTopping property must be of type Pizza. Because of the restriction on this class, all members of IceCream must use the hasTopping property, and therefore must also be members of Pizza. However, Pizza and IceCream are disjoint, so this causes an inconsistency. If they were not disjoint, IceCream would be inferred to be a subclass of Pizza. + Sorvete + + + + + + + + + + + + + + + + + PizzaInteressante + Any pizza that has at least 3 toppings. Note that this is a cardinality constraint on the hasTopping property and NOT a qualified cardinality constraint (QCR). A QCR would specify from which class the members in this relationship must be. eg has at least 3 toppings from PizzaTopping. This is currently not supported in OWL. + + + + + + 3 + + + + + + + + + + + + + CoberturaDeJalapeno + + + + + + + + + + + + + + + + + LaReine + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeLeek + + + + + + + + + + + + + + + + + Margherita + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeCarne + + + + + + + + + + + Any pizza that has at least one meat topping + PizzaDeCarne + + + + + + + + + + + + + + + + + + + Media + + + + + + + + + + + NaoPicante + + + + + + + + + + + CoberturaDeFrutosDoMarMistos + + + + + + + + + + + CoberturaDeMozzarella + + + + + + + + + + + + + + + + + + + + + + + Cogumelo + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeCogumelo + + + + + + + + + + + + + + + + + A pizza that can be found on a pizza menu + PizzaComUmNome + + + + + + + + + + + Napoletana + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Any Pizza that is not a VegetarianPizza + PizzaNaoVegetariana + + + + + + + + + + + + + + + + + + + + CoberturaDeCastanha + + + + + + + + + + + + + + + + + CoberturaDeAzeitona + + + + + + + + + + + + + + + + + CoberturaDeCebola + + + + + + + + + + + + + + + + + CoberturaDePrezuntoParma + + + + + + + + + + + + + + + + + Parmense + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeParmesao + + + + + + + + + + + + + + + + + CoberturaPeperonata + + + + + + + + + + + + + + + + + CoberturaDeCalabreza + + + + + + + + + + + + + + + + + CoberturaDePimentao + + + + + + + + + + + CoberturaPetitPois + + + + + + + + + + + + + + + + + CoberturaPineKernels + + + + + + + + + + + Pizza + + + + + + + + + + + + + + + + + BaseDaPizza + + + + + + + + + + + CoberturaDaPizza + + + + + + + + + + + PolloAdAstra + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeCamarao + + + + + + + + + + + CoberturaPrinceCarlo + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + QuatroQueijos + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + This defined class has conditions that are part of the definition: ie any Pizza that has the country of origin, Italy is a RealItalianPizza. It also has conditions that merely describe the members - that all RealItalianPizzas must only have ThinAndCrispy bases. In essence, all pizzas from Italy must have ThinAndCrispy bases. + PizzaItalianaReal + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeCebolaVermelha + + + + + + + + + + + CoberturaRocket + + + + + + + + + + + + + + + + + Rosa + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaRosemary + + + + + + + + + + + + + + + + + CoberturaEmMolho + + + + + + + + + + + Siciliana + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CoberturaDeTomateFatiado + + + + + + + + + + + + + + + + + SloppyGiuseppe + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Soho + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + A ValuePartition that describes only values from Hot, Medium or Mild. NB Subclasses can themselves be divided up into further partitions. + Tempero + + + + + + + + + + + + + + + + + + + + Any pizza that has a spicy topping is a SpicyPizza + PizzaTemperada + + + + + + + + + + + + + + + + + + + An alternative definition for the SpicyPizza which does away with needing a definition of SpicyTopping and uses a slightly more complicated restriction: Pizzas that have at least one topping that is both a PizzaTopping and has spiciness hot are members of this class. + PizzaTemperadaEquivalente + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Any pizza topping that has spiciness Hot + CoberturaTemperada + + + + + + + + + + + + + + + + + + + CoberturaDeEspinafre + + + + + + + + + + + + + + + + + CoberturaSultana + + + + + + + + + + + + + + + + + CoberturaDeTomateRessecadoAoSol + + + + + + + + + + + + + + + + + CoberturaDePimentaoDoce + + + + + + + + + + + + + + + + + BaseFinaEQuebradica + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MolhoTobascoPepper + + + + + + + + + + + + + + + + + CoberturaDeTomate + + + + + + + + + + + + + + + + + PizzaAberta + An unclosed Pizza cannot be inferred to be either a VegetarianPizza or a NonVegetarianPizza, because it might have other toppings. + + + + + + + + + + + + + + + + + ValorDaParticao + A ValuePartition is a pattern that describes a restricted set of classes from which a property can be associated. The parent class is used in restrictions, and the covering axiom means that only members of the subclasses may be used as values. The possible subclasses cannot be extended without updating the ValuePartition class. + + + + + + + + CoberturaDeVegetais + + + + + + + + + + + PizzaVegetariana + Any pizza that does not have fish topping and does not have meat topping is a VegetarianPizza. Members of this class do not need to have any toppings at all. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Any pizza that only has vegetarian toppings or no toppings is a VegetarianPizzaEquiv1. Should be inferred to be equivalent to VegetarianPizzaEquiv2. Not equivalent to VegetarianPizza because PizzaTopping is not covering + PizzaVegetarianaEquivalente1 + + + + + + + + + + + + + + + + + + + An alternative to VegetarianPizzaEquiv1 that does not require a definition of VegetarianTopping. Perhaps more difficult to maintain. Not equivalent to VegetarianPizza + PizzaVegetarianaEquivalente2 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + An example of a covering axiom. VegetarianTopping is equivalent to the union of all toppings in the given axiom. VegetarianToppings can only be Cheese or Vegetable or....etc. + CoberturaVegetariana + + + + + + + + + + + + + + + + + + + + + + + + + Veneziana + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + NB Transitive - the ingredients of ingredients are ingredients of the whole + + + + + + + + + + + + + + + + + + A property created to be used with the ValuePartition - Spiciness. + + + + + + + + + + + + Note that hasTopping is inverse functional because isToppingOf is functional + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + The inverse property tree to hasIngredient - all subproperties and attributes of the properties should reflect those under hasIngredient. + + + + + + + + + + + + + + + + + + Any given instance of topping should only be added to a single pizza (no cheap half-measures on our pizzas) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/XML/FXMLSample.fxml b/samples/XML/FXMLSample.fxml new file mode 100644 index 00000000..30b56b04 --- /dev/null +++ b/samples/XML/FXMLSample.fxml @@ -0,0 +1,30 @@ + + + + + + + + + +
+ + + + + + + +
+ + + + + + + +
diff --git a/test/test_heuristics.rb b/test/test_heuristics.rb index 7520e828..785fe58e 100644 --- a/test/test_heuristics.rb +++ b/test/test_heuristics.rb @@ -133,6 +133,13 @@ class TestHeuristcs < Minitest::Test }) end + def test_cs_by_heuristics + assert_heuristics({ + "C#" => all_fixtures("C#", "*.cs"), + "Smalltalk" => all_fixtures("Smalltalk", "*.cs") + }) + end + def assert_heuristics(hash) candidates = hash.keys.map { |l| Language[l] } diff --git a/vendor/grammars/NimLime b/vendor/grammars/NimLime index a7067c60..3aab3b38 160000 --- a/vendor/grammars/NimLime +++ b/vendor/grammars/NimLime @@ -1 +1 @@ -Subproject commit a7067c605b893585c056d32a20a1b953f100e138 +Subproject commit 3aab3b3841707e2c1ebac7fad758ec2ca0c7d936 diff --git a/vendor/grammars/SCSS.tmbundle b/vendor/grammars/SCSS.tmbundle index 41475020..8ef6283d 160000 --- a/vendor/grammars/SCSS.tmbundle +++ b/vendor/grammars/SCSS.tmbundle @@ -1 +1 @@ -Subproject commit 41475020634fc07b5c03ff0dfaee64c2491fa32b +Subproject commit 8ef6283dcbd59795b818b646f20a7ff1cd23985f diff --git a/vendor/grammars/Sublime-Inform b/vendor/grammars/Sublime-Inform index c52a11e5..8db129b8 160000 --- a/vendor/grammars/Sublime-Inform +++ b/vendor/grammars/Sublime-Inform @@ -1 +1 @@ -Subproject commit c52a11e50697897469c9ad7c7a59dfdb683db654 +Subproject commit 8db129b8389044a6660ca232566651c8fe3ab646 diff --git a/vendor/grammars/Sublime-Text-2-OpenEdge-ABL b/vendor/grammars/Sublime-Text-2-OpenEdge-ABL index 7b02e1e2..6e8231cc 160000 --- a/vendor/grammars/Sublime-Text-2-OpenEdge-ABL +++ b/vendor/grammars/Sublime-Text-2-OpenEdge-ABL @@ -1 +1 @@ -Subproject commit 7b02e1e2444febb7c6b2179d52de0d2a7cdf5d58 +Subproject commit 6e8231cca124750b413ee50e8a4ee20e36636a03 diff --git a/vendor/grammars/carto-atom b/vendor/grammars/carto-atom index 8086625a..c00fb6c4 160000 --- a/vendor/grammars/carto-atom +++ b/vendor/grammars/carto-atom @@ -1 +1 @@ -Subproject commit 8086625aa5deac4ccd7374644b89e715deec2f7f +Subproject commit c00fb6c461e17de53e9efaf5b495e5b7d877b9d6 diff --git a/vendor/grammars/dart-sublime-bundle b/vendor/grammars/dart-sublime-bundle index d14f6469..3b97e169 160000 --- a/vendor/grammars/dart-sublime-bundle +++ b/vendor/grammars/dart-sublime-bundle @@ -1 +1 @@ -Subproject commit d14f64690cbde6d0bece2670ab385daf89533aea +Subproject commit 3b97e1691ed6aaae24fb8396478c697748fae51a diff --git a/vendor/grammars/factor b/vendor/grammars/factor index 2453a785..208f0141 160000 --- a/vendor/grammars/factor +++ b/vendor/grammars/factor @@ -1 +1 @@ -Subproject commit 2453a785f73429786583684cf729625c7cf7b04b +Subproject commit 208f01416deb340dbac19013b23d398fe4c8d71b diff --git a/vendor/grammars/fsharpbinding b/vendor/grammars/fsharpbinding index 99d2e9a5..9ea14cbe 160000 --- a/vendor/grammars/fsharpbinding +++ b/vendor/grammars/fsharpbinding @@ -1 +1 @@ -Subproject commit 99d2e9a53924ae5ba850985f3df1dc8c11cb6731 +Subproject commit 9ea14cbe3cdcb55215d11863fc4e21fdfa962211 diff --git a/vendor/grammars/haxe-sublime-bundle b/vendor/grammars/haxe-sublime-bundle index e2613bb1..6359431d 160000 --- a/vendor/grammars/haxe-sublime-bundle +++ b/vendor/grammars/haxe-sublime-bundle @@ -1 +1 @@ -Subproject commit e2613bb12598d4ae2de5ba57af890ce910195fce +Subproject commit 6359431d8837ea90f245b29def9e2827ff3f040b diff --git a/vendor/grammars/language-gfm b/vendor/grammars/language-gfm index 6af44a08..18400b22 160000 --- a/vendor/grammars/language-gfm +++ b/vendor/grammars/language-gfm @@ -1 +1 @@ -Subproject commit 6af44a08718668035f45270898389ae4fc8eeb8b +Subproject commit 18400b22cd7968afee982b4e0aa57ef7813ce991 diff --git a/vendor/grammars/language-javascript b/vendor/grammars/language-javascript index 51575193..b47a7fe0 160000 --- a/vendor/grammars/language-javascript +++ b/vendor/grammars/language-javascript @@ -1 +1 @@ -Subproject commit 515751937df1d397b495e4a92fec5a0933994cdb +Subproject commit b47a7fe0cbed2d2553cdb7c6d32e812f9881c21f diff --git a/vendor/grammars/language-python b/vendor/grammars/language-python index 46072e32..0141d449 160000 --- a/vendor/grammars/language-python +++ b/vendor/grammars/language-python @@ -1 +1 @@ -Subproject commit 46072e32e3060eb8e2fea98a106a86db89acc842 +Subproject commit 0141d44946d55ae06ce4dba90b1b0e08db1e437e diff --git a/vendor/grammars/latex.tmbundle b/vendor/grammars/latex.tmbundle index 52b2251a..e413297f 160000 --- a/vendor/grammars/latex.tmbundle +++ b/vendor/grammars/latex.tmbundle @@ -1 +1 @@ -Subproject commit 52b2251aab30577f4b3b3cc8997fb3c7d0e798ce +Subproject commit e413297f3af499f2c87c5fb92c6d3199f25fa586 diff --git a/vendor/grammars/nesC.tmbundle b/vendor/grammars/nesC.tmbundle index 5958c490..d0d322ce 160000 --- a/vendor/grammars/nesC.tmbundle +++ b/vendor/grammars/nesC.tmbundle @@ -1 +1 @@ -Subproject commit 5958c490262e4a5a7803d97c9ec770bd40307153 +Subproject commit d0d322ceafe3c4d8affc0e8b767fb6ad65c52704 diff --git a/vendor/grammars/standard-ml.tmbundle b/vendor/grammars/standard-ml.tmbundle index af5395b6..791c8b20 160000 --- a/vendor/grammars/standard-ml.tmbundle +++ b/vendor/grammars/standard-ml.tmbundle @@ -1 +1 @@ -Subproject commit af5395b606273b53e7dd3550270cff7f886d3cc3 +Subproject commit 791c8b2054b4c12edcee29d73945c0db53e447e9 diff --git a/vendor/grammars/sublime-rust b/vendor/grammars/sublime-rust index 9609ab44..40df3591 160000 --- a/vendor/grammars/sublime-rust +++ b/vendor/grammars/sublime-rust @@ -1 +1 @@ -Subproject commit 9609ab4418ed6667e06edea83d7fa157827a2923 +Subproject commit 40df35916158b680eb3d9acb9080a03f7799144c diff --git a/vendor/grammars/sublimetext-cuda-cpp b/vendor/grammars/sublimetext-cuda-cpp index 3ed68f99..e51269fc 160000 --- a/vendor/grammars/sublimetext-cuda-cpp +++ b/vendor/grammars/sublimetext-cuda-cpp @@ -1 +1 @@ -Subproject commit 3ed68f996137ad684d822463bcda1bfd1de00232 +Subproject commit e51269fc22602d3f7aaac0266fc189c4ed4a3901 diff --git a/vendor/grammars/swift.tmbundle b/vendor/grammars/swift.tmbundle index 3c7eac54..0cd27c70 160000 --- a/vendor/grammars/swift.tmbundle +++ b/vendor/grammars/swift.tmbundle @@ -1 +1 @@ -Subproject commit 3c7eac54457aa8f953fa5263cb34ec4dc9555217 +Subproject commit 0cd27c708953230e10571ccb88a4b24eedf762bb diff --git a/vendor/grammars/text.tmbundle b/vendor/grammars/text.tmbundle index c536e814..961652ad 160000 --- a/vendor/grammars/text.tmbundle +++ b/vendor/grammars/text.tmbundle @@ -1 +1 @@ -Subproject commit c536e81409d1fa1fc24f388f70b0513c3a8bfc59 +Subproject commit 961652ad957678e75b533406de1be5bd7f489063 diff --git a/vendor/grammars/turtle.tmbundle b/vendor/grammars/turtle.tmbundle new file mode 160000 index 00000000..0782b476 --- /dev/null +++ b/vendor/grammars/turtle.tmbundle @@ -0,0 +1 @@ +Subproject commit 0782b476573a317917fb9b3bbe7e6a68abefa7a5