Syntax checking is the verification that a program's source code is technically correct according to the rules of that programming language.
Questions tagged [syntax-checking]
110 questions
10
votes
5 answers
math syntax checker written in python
All I need is to check, using python, if a string is a valid math expression or not.
For simplicity let's say I just need + - * / operators (+ - as unary too) with numbers and nested parenthesis. I add also simple variable names for completeness.
So…

neurino
- 11,500
- 2
- 40
- 63
10
votes
3 answers
Member access call does not compile but static call does
So today I faced interesting problem while trying to build our company solution and I wanted to ask you guys do you know why is this happening. I've been told that it might be from my machine/visual studio because other people did not have same…

kuskmen
- 3,648
- 4
- 27
- 54
9
votes
3 answers
Are there any AWK syntax checkers?
Are there any AWK syntax checkers? I'm interested in both minimal checkers that only flag syntax errors and more extensive checkers along the lines of lint.
It should be a static checker only, not dependent on running the script.

Michael J. Barber
- 24,518
- 9
- 68
- 88
8
votes
3 answers
Checking C# Syntax from the Command Line
Does anyone know of a way in the Microsoft .NET framework to check the syntax, and only the syntax, of a given C# file?
For a little background, what I am interested in doing is setting up syntastic to check the syntax of .cs files. Out of the box,…

Michael
- 1,306
- 1
- 12
- 30
7
votes
3 answers
How to selectively disable checkers for certain file types when using syntastic in vim?
For example, HTML partial templates are being flagged with tons of errors but they are supposed to be fragments of a complete HTML doc.

Eno
- 10,730
- 18
- 53
- 86
7
votes
2 answers
JavaScript syntax check in eclipse
I am developing a RIA application with JavaScript in Eclipse. How can I enable JavaScript syntax check in eclipse?

flybywire
- 261,858
- 191
- 397
- 503
6
votes
3 answers
Can Visual Studio target earlier C# syntax in addition to earlier .NET framework versions?
The easy part:
Targeting the .NET 2.0 framework in a Visual Studio 2010 project using the dropdown.
The hard part:
Is it possible to target a specific syntax version - for example var s = "hello world" is valid syntactic sugar in VS2008 and above,…

David
- 24,700
- 8
- 63
- 83
6
votes
1 answer
How to find out syntax error of a single line JavaScript code?
Say, there is a text box. User written the following code:
document.getElementById("id").;
It will surely cause some syntax error.
There is also a "RUN" button. my requirement is :
if user click on that button, the code written in the text box…

Amit Pal
- 61
- 1
6
votes
2 answers
cin.get() not working
I wrote this simple program today, but I found that cin.get() refuses to work unless there are 2 of them. Any ideas?
#include
using namespace std;
int main(){
int base;
while ((base < 2) || (base > 36)){
cout << "Base…

calccrypto
- 8,583
- 21
- 68
- 99
6
votes
3 answers
How do I check SQLite3 syntax?
Is there a way to check the syntax of a SQLite3 script without running it?
Basically, I'm looking for the SQLite3 equivalent of ruby -c script.rb, perl -c script.pl, php --syntax-check script.php, etc.
I've thought of using explain, but most of the…

Benjamin Oakes
- 12,262
- 12
- 65
- 83
6
votes
3 answers
How can I disable "HTML Checking" in NetBeans?
I'm using NetBean's Compile on Save setting, and it's really handy when I'm editing a single file. But when I'm dealing with a pair of (or more) class files and am switching between the files, I have a problem:
The Task tab is nearly worthless…

NVRAM
- 6,947
- 10
- 41
- 44
6
votes
6 answers
Syntax Checking or "Compiling" a Ruby on Rails Application
I'm new to Ruby and recently ran into an issue comparing to values when creating a Ruby on Rails application. In a controller I had the following statement that always returned false:
if (user.id != params[:id])
The problem was the user.id (which…

Chris C
- 373
- 7
- 17
5
votes
4 answers
Testing Powershell scripts for correctness
Is their anyway to test the correctness of a powershell script without executing it. I know you could do something similar in unix, but can't find the equiv for powershell.
Essentially what I have is a script repository, where each script is tied…

scope_creep
- 4,213
- 11
- 35
- 64
5
votes
2 answers
How to syntax check VHDL in Vivado without complete synthesis
What's the simplest way to syntax-check my VHDL in Vivado without running through a full synthesis?
Sometimes I code many inter-related modules at once, and would like to quickly find naming errors, missing semi-colons, port omissions, etc. The…

edj
- 523
- 7
- 17
5
votes
1 answer
static/compile time check for javascript with jquery?
I know javascript (or at least a version of it) can be compiled into .NET provided certain conditions are met. How can i do a compile time or static syntax check on javascript i am writing? The catch is, it must support jquery
Cause someone will…
user34537