From aa05cf6073cf2a6dfa46108cd5522c0171a7f1c3 Mon Sep 17 00:00:00 2001 From: Benjamin Barenblat Date: Thu, 30 Jul 2015 16:51:31 -0400 Subject: Make library work on both client and server sides Replace the two-step compile/match process with a single compile-and-match one to avoid issues with server-client representation incompatibility. Use the browser regex engine on the client side. --- src/regex__FFI.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'src/regex__FFI.h') diff --git a/src/regex__FFI.h b/src/regex__FFI.h index 4cf5435..695033a 100644 --- a/src/regex__FFI.h +++ b/src/regex__FFI.h @@ -1,4 +1,5 @@ /* Copyright (C) 2015 the Massachusetts Institute of Technology +Copyright (C) 2015 Benjamin Barenblat Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the @@ -24,8 +25,6 @@ extern "C" { #include -typedef void* uw_Regex__FFI_regex; - typedef struct { char* haystack; void* result; @@ -41,12 +40,8 @@ uw_Basis_string uw_Regex__FFI_subexpression_match(struct uw_context*, const uw_Regex__FFI_match, const uw_Basis_int); -uw_Regex__FFI_regex uw_Regex__FFI_compile(struct uw_context*, - const uw_Basis_bool, - const uw_Basis_string); - uw_Regex__FFI_match uw_Regex__FFI_do_match(struct uw_context*, - const uw_Regex__FFI_regex, + const uw_Basis_string, const uw_Basis_string); #ifdef __cplusplus -- cgit v1.2.3