Skip to content

Commit

Permalink
resolve a few other issues, appears to deploy happily now...
Browse files Browse the repository at this point in the history
  • Loading branch information
sanity committed Mar 10, 2012
1 parent 2b6dee6 commit 30f5224
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 84 deletions.
23 changes: 14 additions & 9 deletions src/com/lastcalc/parsers/UserDefinedParserParser.java
Expand Up @@ -2,15 +2,15 @@
* LastCalc - The last calculator you'll ever need
* Copyright (C) 2011, 2012 Uprizer Labs LLC
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published
* by the Free Software Foundation, either version 3 of the License, or
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published
* by the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU Affero General Public License for more
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU Affero General Public License for more
* details.
******************************************************************************/
package com.lastcalc.parsers;
Expand Down Expand Up @@ -218,7 +218,10 @@ public ParseResult parse(final TokenList tokens, final int templatePos, final Pa
return ParseResult.fail();

final List<Object> result = Lists.newArrayListWithCapacity(after.size() + 2);
result.add("(");
final boolean useBrackets = tokens.size() > template.size();
if (useBrackets) {
result.add("(");
}
final TokenList input = tokens.subList(templatePos, templatePos + template.size());
final Map<String, Object> varMap = Maps.newHashMapWithExpectedSize(variables.size());
try {
Expand All @@ -234,7 +237,9 @@ public ParseResult parse(final TokenList tokens, final int templatePos, final Pa
} catch (final BindException e) {
return ParseResult.fail();
}
result.add(")");
if (useBrackets) {
result.add(")");
}
final TokenList resultTL = TokenList.create(result);
final TokenList flattened = PreParser.flatten(resultTL);
return ParseResult.success(
Expand Down
15 changes: 0 additions & 15 deletions war/WEB-INF/appengine-web.xml
@@ -1,19 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
LastCalc - The last calculator you'll ever need
Copyright (C) 2011, 2012 Uprizer Labs LLC
This program is free software: you can redistribute it and/or modify it
under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the GNU Affero General Public License for more
details.
-->
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
<application>lastcalc-upr</application>
<version>1</version>
Expand Down
15 changes: 0 additions & 15 deletions war/WEB-INF/datastore-indexes.xml
@@ -1,19 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
LastCalc - The last calculator you'll ever need
Copyright (C) 2011, 2012 Uprizer Labs LLC
This program is free software: you can redistribute it and/or modify it
under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the GNU Affero General Public License for more
details.
-->
<datastore-indexes autoGenerate="true">
<datastore-index kind="Worksheet" ancestor="false"
source="auto">
Expand Down
15 changes: 0 additions & 15 deletions war/WEB-INF/logging.properties
@@ -1,18 +1,3 @@
#-------------------------------------------------------------------------------
# LastCalc - The last calculator you'll ever need
# Copyright (C) 2011, 2012 Uprizer Labs LLC
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU Affero General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU Affero General Public License for more
# details.
#-------------------------------------------------------------------------------
# A default java.util.logging configuration.
# (All App Engine logging is through java.util.logging by default).
#
Expand Down
15 changes: 0 additions & 15 deletions war/WEB-INF/web.xml
@@ -1,19 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
LastCalc - The last calculator you'll ever need
Copyright (C) 2011, 2012 Uprizer Labs LLC
This program is free software: you can redistribute it and/or modify it
under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the GNU Affero General Public License for more
details.
-->
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
Expand Down
15 changes: 0 additions & 15 deletions war/noie.html
@@ -1,18 +1,3 @@
#-------------------------------------------------------------------------------
# LastCalc - The last calculator you'll ever need
# Copyright (C) 2011, 2012 Uprizer Labs LLC
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU Affero General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU Affero General Public License for more
# details.
#-------------------------------------------------------------------------------
<html>
<head>
<title>LastCalc: Your browser is not supported :-(</title>
Expand Down

0 comments on commit 30f5224

Please sign in to comment.