Results 1 to 4 of 4
  1. #1
    Yemiez's Avatar
    Join Date
    Jun 2012
    Gender
    male
    Location
    Sweden
    Posts
    2,566
    Reputation
    731
    Thanks
    16,280
    My Mood
    Devilish

    Expression Parser Release [1x5]

    Introduction
    Welcome to the release of Expression parser version 1x5.
    This is going to be a short thread as all the necessary information can be found in my other threads created about ep, they can be seen at the bottom of this page.

    What is Expression Parser?
    Ep, which by the way is short for Expression Parser, is a new scripting language created for the sole purpose of being used by MPGH members exclusively. It's meant to work along the side of C++, meaning you can directly use ep in your C++ Applications by simply including the ep headers and libraries. The now improved C++ portability means you can have ep arguments (variable_list) automatically deduced into arguments at C++ compile time.

    I wanna learn more, how does it work?
    Expression Parser Theoretical Introduction
    Expression Parser Practical and Syntactical Introduction


    Changelog
    Version 1x2
    Code:
    - First release
    Version 1x3
    Code:
    - You can now include files with the import keyword, by simply using "" operator.
        Example:
          import "myfile.ep";
      
    - Cleaned up some module code.
    
    - Fixed a logical error inside of the optimizer. 
      (It optimized correctly, but after said optimization the cursor would be at the wrong position)
      
    - Fixed bug in the engine constructor leading to undefined behaviour.
    
    - Fixed fake conversion bug in ostream::put and ostream::putln. 
      (It would always throw a conversion error)
    Version 1x4
    Code:
    - Fixed another optmization bug where dead code optmization would only remove the first type of dead code.
      e.g:
        5 + 5;
        6 + 5;
      would optimize to:
        6 +5; 
      when really there should be no blocks left.
    
    - Added plugins (aka import modules)
        Recommended usage:
            use function ep::load_plugins to load multiple plugins at once (e.g ep::module( ep::load_plugins( "v1", "v2" )))
            A plugin must contain the following functions:
                exern "C" __declspec(dllexport) void load_plugin( dispatch_engine_ptr );
                exern "C" __declspec(dllexport) const char *get_name( );
            
    - FINALLY FIXED OPERATOR -> GLITCHES, YOU CAN NOW USE IT HOWEVER THE
      YOU DESIRE. FK YEA.
    Version 1x5
    Code:
    - Fixed another bug with the '->' operator
    	Example:
    		x()->y()->z()
    	Wouldn't work, because the interpreter only considered
    	value references from lvalue's, hence the above expression
    	would be undefined behavour. (Would most like throw "invalid -> usage")
    	
    - Added the 'make_method' operator, it processes and makes a ep::method_ptr from a
      c++ callable.
      
    - Added some C++ compile time error messages.
    	
    - Fixed a value reference bug:
    	Previous to 1x5 the following C++ function:
    		type *get_self_ptr( )
    		{
    			return this;
    		};
    		
    		"get_self_ptr",
    		[]( type *obj )
    		{
    			return std::make_shared<ep::value_reference>( obj->get_self_ptr( ),
    				                                          engine->get_type_info( "" ) );
    		};
    	
    	And if you then added that member method onto the type "type",
    	and do this in ep:
    		auto test = type(); // Construct..
    		test->get_self_ptr(); // call...
    		// Now 'test' has been destructed. Because
    		// the rvalue of 'get_self_ptr' is destructed
    		// at the end of the expression.
    		
    	which is why I added the possibilty to determine if a value_reference should be destructed,
    	simply pass another argument to the constructor of value_reference of type bool,
    	you only need to specify it if it's not supposed to be destructed, it is default true.
    		"get_self_ptr",
    		[]( type *obj )
    		{
    			return std::make_shared<ep::value_reference>( obj->get_self_ptr( ),
    				                                          engine->get_type_info( "" ),
    				                                          false ); // don't destruct.
    		};
    Sincerely,
    Yamiez.
    <b>Downloadable Files</b> Downloadable Files

  2. The Following 4 Users Say Thank You to Yemiez For This Useful Post:

    [MPGH]Ahl (10-05-2016),Ally (10-05-2016),[MPGH]Hero (10-05-2016),[MPGH]Hugo Boss (10-05-2016)

  3. #2
    Yemiez's Avatar
    Join Date
    Jun 2012
    Gender
    male
    Location
    Sweden
    Posts
    2,566
    Reputation
    731
    Thanks
    16,280
    My Mood
    Devilish
    Not getting much attention yet, nontheless here's a sneak peak of the upcoming update:

    Working groups:


    Silky smooth error messages:

  4. The Following 2 Users Say Thank You to Yemiez For This Useful Post:

    [MPGH]Hugo Boss (10-07-2016),Hunter (10-07-2016)

  5. #3
    Yemiez's Avatar
    Join Date
    Jun 2012
    Gender
    male
    Location
    Sweden
    Posts
    2,566
    Reputation
    731
    Thanks
    16,280
    My Mood
    Devilish
    @Hodor @Hugo Boss Close and mark as "Outdated",
    Thanks

  6. #4
    Hunter's Avatar
    Join Date
    Dec 2013
    Gender
    male
    Location
    Depths Of My Mind.
    Posts
    17,468
    Reputation
    3771
    Thanks
    6,159
    My Mood
    Cheerful
    /Outdated, closed.

Similar Threads

  1. [Outdated] Expression Parser Release [1x6]
    By Yemiez in forum Coders Lounge
    Replies: 3
    Last Post: 10-10-2016, 06:14 AM
  2. [Outdated] Expression Parser Release [1x4]
    By Yemiez in forum Coders Lounge
    Replies: 1
    Last Post: 10-05-2016, 06:12 AM
  3. [Outdated] Expression Parser Release [1x3]
    By Yemiez in forum Coders Lounge
    Replies: 6
    Last Post: 10-05-2016, 05:36 AM
  4. [Outdated] Expression Parser Release [1x2]
    By Yemiez in forum Coders Lounge
    Replies: 1
    Last Post: 10-02-2016, 10:14 AM
  5. [Info] Expression Parser Theoretical Introduction
    By Yemiez in forum Coders Lounge
    Replies: 0
    Last Post: 10-01-2016, 09:01 AM