changed Awk to use HashTable instead of htb.
added Cstr, Mcstr, Wcstr. changed Awk not to use in-class placement new in allocating a value
This commit is contained in:
@ -25,6 +25,7 @@
|
||||
*/
|
||||
|
||||
#include <qse/awk/StdAwk.hpp>
|
||||
#include <qse/cmn/HeapMmgr.hpp>
|
||||
#include <qse/cmn/opt.h>
|
||||
#include <qse/cmn/main.h>
|
||||
#include <qse/cmn/mbwc.h>
|
||||
@ -52,7 +53,7 @@ typedef QSE::StdAwk::Value Value;
|
||||
class MyAwk: public StdAwk
|
||||
{
|
||||
public:
|
||||
MyAwk () { }
|
||||
MyAwk (QSE::Mmgr* mmgr = QSE_NULL): StdAwk (mmgr) { }
|
||||
~MyAwk () { close (); }
|
||||
|
||||
int open ()
|
||||
@ -428,6 +429,8 @@ static int awk_main_2 (MyAwk& awk, int argc, qse_char_t* argv[])
|
||||
|
||||
static int awk_main (int argc, qse_char_t* argv[])
|
||||
{
|
||||
//QSE::HeapMmgr hm (1000000);
|
||||
//MyAwk awk (&hm);
|
||||
MyAwk awk;
|
||||
|
||||
if (awk.open() <= -1)
|
||||
|
@ -17,7 +17,7 @@ public:
|
||||
// printf ("destructor\n");
|
||||
}
|
||||
bool operator== (const T& x) const { return this->x == x.x; }
|
||||
qse_size_t hashCode() const { return x; }
|
||||
qse_size_t getHashCode() const { return x; }
|
||||
|
||||
int getValue() const { return this->x; }
|
||||
int getY() const { return this->y; }
|
||||
|
Reference in New Issue
Block a user