Git Product home page Git Product logo

condor's People

Contributors

boranyldrm avatar chasewillden avatar suriyaakudoisc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

condor's Issues

std::stof and std::stol Rounding Issues

When running the following code:

import "println" from "console"

int ten1 = 10;
float tenf = 10.1;
double tend = 10.1;
long tenl = 10.1;

println(ten1 + 10);
println(tenf + 10);
println(tend + 10);
println(tenl + 10);

The following output occurs:

20
20.100000000000001
10
20.100000000000001

A 1 exists at the end. I've isolated where it exactly occurs, but I haven't been able to find out why.

Shell building

Expected Behavior

No errors and some eventual log outputed onto the terminal

Current Behavior

g++  -I ./ test/shell.cc -Iinclude build/libcondor.a -o build/linux/condor
test/shell.cc: In function ‘int main(int, const char**)’:
test/shell.cc:24:35: error: ‘to_string’ is not a member of ‘std’
  std::cout << "CondorLang (C) " + std::to_string(year) + "\n";
                                   ^
test/shell.cc:32:16: error: no matching function for call to ‘Condor::Script::Free()’
   script->Free();
                ^
In file included from test/shell.cc:6:0:
include/Condor.h:60:8: note: candidate: void Condor::Script::Free(Condor::Isolate*)
   void Free(Isolate* isolate);
        ^
include/Condor.h:60:8: note:   candidate expects 1 argument, 0 provided
Makefile:108: recipe for target 'shell' failed
make: *** [shell] Error 1

Possible Solution

  1. Making sure that to_string is a member of std (see l.24 of the code)
  2. Making sure that Free is an accessible method in Condor::Script (see l.32 of the code)
  3. Add the appropriate argument to Free (see 2. above)

Steps to Reproduce

git clone https://github.com/CondorLang/Condor/
cd Condor
make all
make || make mt
make shell

Context (Environment)

I was trying to set up the CondorLang dev environment (to use/test/improve it) on Linux Ubuntu 16.04 LTS (64-bit) and I run into this problem.

println

import "println" from "console"
import "string"
 
println("asd");
println(strlen("asd"));

Just prints the second one.

Garbage Collection in For Loop

The following code does not increase memory:

for (int i = 0; i < 100; i++) var a = 10;

The memory is under control, meaning, the garbage collector is cleaning this properly. However, when I run the following code:

for (int i = 0; i < 100; i++) var a = 10 + 10;

The memory nearly doubles. The garbage collection is not occurring here.
Here is a starting place

To replicate the issue:

  1. Open System Monitor/Activity Monitor
  2. Run ./build/condor
  3. Check if Condor is a task on the activity monitor
  4. run the two code examples above

Recursion Bug with GC

The GC is not working properly when there is recursion. See the Code

Example Code:

import "println" from "console"
func fib(int n){
    println("-> " + n);
    if (n == 0) return 0;
    else if (n == 1) return 1;
    else return fib(n - 1) + fib(n - 2);
}

int val = fib(2);
println(val);

Questions

Hi,
I saw your post on Quora: https://www.quora.com/How-can-I-find-people-to-contribute-to-my-open-source-Github-project/draft
I'm the one who said: "
Post in Open Source (and eventually on CompSci/Soft Eng) groups/communities to get people to eventually contribute.
There's a quite a lot of those on social networks like G+ and FB so don't be afraid to join them.
"

I went through the repo and I'm wondering if it's an extension to C# or it's an actual language where we could add stuff from JS for instance ?
I'm asking this because I'm quite noobish in VB/C#/C++ but I noticed a lot of JS-like snippets which I think could be improved.

make mem error

I got this after running make mem

valgrind --tool=memcheck --leak-check=full --track-origins=yes --dsymutil=yes ./build/Cobra > log.txt 2>&1
Makefile:57: recipe for target 'mem' failed
make: *** [mem] Error 127

[Build test fail] make || make mt

Expected Behavior

Not having this:

2154
*** Error in `./build/Cobra': double free or corruption (!prev): 0x0000000000e56970 ***
Makefile:49: recipe for target 'test' failed
make[1]: *** [test] Aborted (core dumped)
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
Makefile:10: recipe for target 'mt' failed
make: *** [mt] Error 2

Actual Behavior

Whenever I run: make || make mt or even both apart I get this twice (so once for make and once for make mt):

make all
make[1]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make buildAll
make[2]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make[2]: Nothing to be done for 'buildAll'.
make[2]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make lib
make[2]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make[2]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make test
make[1]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
g++  -I ./ test/main.cc -Iinclude build/libcobra.a -o build/Cobra
./build/Cobra 
2154
*** Error in `./build/Cobra': double free or corruption (!prev): 0x0000000000e56970 ***
Makefile:49: recipe for target 'test' failed
make[1]: *** [test] Aborted (core dumped)
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
Makefile:10: recipe for target 'mt' failed
make: *** [mt] Error 2
2154
*** Error in `./build/Cobra': double free or corruption (!prev): 0x0000000000e56970 ***
Makefile:49: recipe for target 'test' failed
make[1]: *** [test] Aborted (core dumped)
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
Makefile:10: recipe for target 'mt' failed
make: *** [mt] Error 2
make all
make[1]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make buildAll
make[2]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make[2]: Nothing to be done for 'buildAll'.
make[2]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make lib
make[2]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
make[2]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
make test
make[1]: Entering directory '/home/maxie/Desktop/Languages/CobraLang'
g++  -I ./ test/main.cc -Iinclude build/libcobra.a -o build/Cobra
./build/Cobra 
2154
*** Error in `./build/Cobra': double free or corruption (!prev): 0x0000000001638970 ***
Makefile:49: recipe for target 'test' failed
make[1]: *** [test] Aborted (core dumped)
make[1]: Leaving directory '/home/maxie/Desktop/Languages/CobraLang'
Makefile:10: recipe for target 'mt' failed
make: *** [mt] Error 2

Steps to Reproduce the Problem

  1. Clone the repo at the cloned repo of CobraLang (/home/maxie/Desktop/Languages/CobraLang for me)
  2. Run make then make || make mt
  3. See what the terminal display

Specifications

  • OS: Ubuntu 15.04
  • Terminal used: gnome-terminal

Fix Shell Up, Down, Left, and Right Arrow

When running ./build/condor, running in shell mode, the usage of the left, up, down, and right arrow does not work. The symbol [^A or something like that appear.

Building the memory tests

Expected Behavior

Memory test results.

Current Behavior

valgrind --tool=memcheck --leak-check=full --track-origins=yes --dsymutil=yes ./build/linux/condor > log.txt 2>&1
Makefile:112: recipe for target 'mem' failed
make: *** [mem] Error 127

Steps to Reproduce

git clone https://github.com/CondorLang/Condor/
cd Condor
make all
make || make mt
make shell
sudo apt-get install valgrind
make mem #note: runing sudo apt-get update before gives the same result when running this line

Context (Environment)

I was trying to set up the CondorLang dev environment (to use/test/improve it) on Linux Ubuntu 16.04 LTS (64-bit) and I run into this problem.

There is already a Cobra language

First, congratulations are creating a new language!

Second, the following language has been out for several years and has been called Cobra the entire time: http://cobra-language.com/

It has a wikipedia entry and is referenced on the Python wikipedia page:
https://en.wikipedia.org/wiki/Python_(programming_language)#Languages_influenced_by_Python

It's also been covered by InfoWorld and other places.

I think choosing the same name is inappropriate and potentially confusing. I recommend picking a name that doesn't duplicate existing languages. Here is a list:
http://regulargeek.com/2012/12/08/the-big-list-of-256-programming-languages/

Or you can search google for "foo programming language" for any candidate name "foo"

Best regards,

Charles Esterbrook
Creator of Cobra

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.