only remove a leading - if word char following to avoid murdering e.g. --
Matt S Trout [Wed, 27 Mar 2019 01:21:55 +0000 (01:21 +0000)]
lib/SQL/Abstract.pm

index 2661082..0eff852 100644 (file)
@@ -703,7 +703,7 @@ sub _expand_expr_hashpair_op {
   my ($self, $k, $v) = @_;
 
   my $op = $k;
-  $op =~ s/^-// if length($op) > 1;
+  $op =~ s/^-(?=\w)//;
   $self->_assert_pass_injection_guard($op);
 
   # Ops prefixed with -not_ get converted