Data dodania Pytanie
2017-01-04 23:01 How does ruby parse 2 /3/ 4 as 2 ÷ 3 ÷ 4? »
A lot of ruby's syntax and parsing is relatively logical, but I am confused as to how ruby knows, from context, that 2 /3/ 4 is 2 ÷ 3 ÷ 4 instead of...
(1) odpowiedzi
2016-12-29 03:12 BeautifulSoup `find_all` generator »
Is there any way to turn find_all into a more memory efficient generator? For example: Given: soup = BeautifulSoup(content, "html.parser") return ...
(3) odpowiedzi
2016-12-24 01:12 Python: how to Parse and check the time? »
How do I extract the IP address that occurs 10 times within a one-second time interval? In the following case: 241.7118.197.10 28.252.8 ...
(2) odpowiedzi
2016-12-21 10:12 How to parse files that cannot fit entirely in memory RAM »
I have created a framework to parse text files of reasonable size that can fit in memory RAM, and for now, things are going well. I have no complaints...
(6) odpowiedzi
2016-12-19 12:12 ruby rspec in `block (2 levels) in <top (required)>' »
I have problems with error message ./spec/models/lib/parsers/s_reality_cz/matcher_spec.rb:12:in `block (2 levels) in ' in every rspec test. What I'm d...
(1) odpowiedzi
2016-12-01 14:12 split String by space separated »
I need to split words by space separated in java, so I have used .split function in-order to achieve that like as shown below String keyword = "appl...
(5) odpowiedzi
2016-12-01 14:12 Parsing C# Conditional Compilation statements in roslyn »
How do I parse C# conditional compilation statement using Roslyn. In the following code, I want Roslyn to give the Conditional compilation statement ...
(2) odpowiedzi
2016-11-20 10:11 Ruby on sinatra, JSON::parserError issue and 757: unexpected token »
I use rest API on Ruby with sinatra. I got payment information from IAMPORT,,, def get_authrestapi() @key = IMP_KEY @secret = IMP_SECRET ...
(1) odpowiedzi
2016-11-19 11:11 How can the PL/SQL grammar included with ANTLR4 be tested? »
I'm just getting started using ANTLR, and want to try test parsing some simple PL/SQL statements using the plsql.g4 grammar. I am following the format...
(1) odpowiedzi
2016-11-14 13:11 how can I store a string without "" in common lisp? »
Im trying to store in a: (seft a (read-from-string ".")) in order to get a = . not a = "." but it doesnt work. ...
(2) odpowiedzi
2016-11-09 10:11 Is there a way to force an attoparsec not to backtrack? »
I've written some parsers using Attoparsec but only now realised that I don't always want them to backtrack on failure, but attoparsec parsers always ...
(0) odpowiedzi
2016-11-05 11:11 Creating a JRuby parser implementation to generate AST from java file »
I am currently trying to parse the following java code to get an AST from my .java files in a jrubyparser implementation: import static org.junit.Ass...
(1) odpowiedzi
2016-10-26 17:10 Why does Roslyn have two versions of syntax per language? »
I have been looking at the Roslyn code base and noticed that they have two versions of syntax(One internal and one public). Often these appear to be r...
(1) odpowiedzi
2016-10-26 08:10 How can I retrieve Enum from char value? (C#) »
I have the following enum public enum MaritalStatus { Married = 'M', Widow = 'W', Widower = 'R', Single='S' } In one function I hav...
(3) odpowiedzi
2016-10-24 21:10 Set literal gives different result from set function call »
Why does the set function call wipe out the dupes, but parsing a set literal does not? >>> x = Decimal('0') >>> y = complex(0,0) &g...
(2) odpowiedzi
2016-10-13 23:10 How can I find all known ingredient strings in a block of text? »
Given a string of ingredients: text = """Ingredients: organic cane sugar, whole-wheat flour, mono & diglycerides. Manufactured in a faci...
(1) odpowiedzi
2016-10-10 09:10 Using arbitrary trees with Free Monads in Scala+Cats »
I am creating a library for grammars that will have 2 different interpretations: 1) parsing strings based on the grammar 2) generating strings in the ...
(0) odpowiedzi
2016-10-06 17:10 How do you match a string surrounded by optional whitespace with SBT Parsers »
I'm trying to parse a command line argument for an sbt InputTask using SBT Parsers (http://www.scala-sbt.org/0.13/docs/Parsing-Input.html) but I'm fai...
(0) odpowiedzi
2016-09-27 14:09 Adding Xml Attribute to All elements except root Node »
I am trying to add new attribute to my xml files in c#. my xml file format is shown below: <Root MessageOfRoot="Welcome to Xml"> <Header...
(1) odpowiedzi
2016-09-26 13:09 java.lang.NumberFormatException for input string "1" »
So, I have an issue that really bothers me. I have a simple parser that I made in java. Here is the piece of relevant code: while( (line = br.readLin...
(1) odpowiedzi
2016-09-25 15:09 Testing of a new Java parser »
Purely as a self-learning exercise, I'm trying to write a Java parser in Perl using the Parse::RecDescent module. I may later re-implement the parser ...
(1) odpowiedzi
2016-09-14 16:09 Basic access authentication in Chrome url fails (http) »
Since few days, I noticed an issue in url parsing in chrome that worked previously. Indeed when using basic access authentification directly in url u...
(0) odpowiedzi
2016-09-10 08:09 Correctly Parsing JSON in Swift 3 »
I'm trying to fetch a JSON response and store the results in a variable. I've had versions of this code work in previous releases of Swift, until the ...
(2) odpowiedzi
2016-08-25 09:08 Parsing float stored as string should throw Exception »
I have a string which stores a number. Now i want to parse that string and get as float. import java.util.*; import java.lang.*; import java.io.*; ...
(1) odpowiedzi
2016-08-22 04:08 How to express parsing logic in Parsec ParserT monad »
I was working on "Write Yourself a Scheme in 48 hours" to learn Haskell and I've run into a problem I don't really understand. It's for question 2 fro...
(2) odpowiedzi
2016-08-17 11:08 Read a file and convert into an n-ary tree based nested list in Common Lisp? »
For one of my projects, I am trying to use Common Lisp, specifically SBCL (in the process, learning it. This is one of the motivations.) I need to re...
(1) odpowiedzi
2016-08-15 17:08 Extend EvalMath with boolean operators »
I've try to extend class from answer to this question: How to evaluate formula passed as string in PHP? with operators < > <= >= == &&...
(1) odpowiedzi
2016-08-02 16:08 Valid RegEx according to online test tools, not getting any matches when reading file in browser »
I've designed this regex with several online tools and with help of the community: https://regex101.com/r/hJ4pD5/1 (\s[A-Z]\.).+?(?=(\s[A-Z]\.)|(\W?...
(1) odpowiedzi
2016-08-01 20:08 Most efficient way to parse URL's with handling errors and extracting required values »
I have the Problem framed in the below Program i am trying to extract values from URL strings like the values that come after a=, symbol=, uid=, cid=,...
(1) odpowiedzi
2016-07-30 13:07 how to display json and parse json in ruby using httparty »
I am working on a food app in ruby on rails which requires to get calorie value of food item from food api.In my controller i am getting the JSON res...
(1) odpowiedzi
2016-07-21 20:07 How to simulate a symbol table in Common Lisp »
i am learning Common LISP at the moment and i encountered a huge roadblock. I've had an assignment that we were to learn how to create a parser in Com...
(2) odpowiedzi
2016-07-17 22:07 Replace trivia with node in Roslyn »
For example, I have the following documentation comment in my C# code file: /// add k+5 I want to REPLACE it with the node _tst.AddElement(k+5); ...
(2) odpowiedzi
2016-07-08 10:07 Swift 2 save multiple images to Parse »
I have an array of images and i would like to upload them in a Class in Parse but in separate lines with a pointer to another class. So my code struc...
(1) odpowiedzi
2016-07-01 23:07 How to parse through each XML element/XML children in Coldfusion »
I am trying to get the xmltext of the children for each element (there are 377 elements). The inner loop is what I am unsure about. I don't even know ...
(1) odpowiedzi
2016-06-28 10:06 How to handle case-insensitive keywords with Scala parser combinators »
Some languages, like SQL, have case-insensitive keywords (and/or identifiers). When using TokenParsers, how can I handle this case insensitivity? One ...
(1) odpowiedzi