 (def ^:const uri-match-end-index :calfpath/uri-match-end-index)
 
 
-(definline get-uri-match-end-index
+(defmacro get-uri-match-end-index
   [request]
   `(or (get ~request uri-match-end-index) 0))
 
 
-(definline assoc-uri-match-end-index
+(defmacro assoc-uri-match-end-index
   [request end-index]
   `(assoc ~request uri-match-end-index ~end-index))
 

                         (partial-match (persistent! path-params) actual-index))
                       (full-match (persistent! path-params)))
                     (let [token (get pattern-tokens token-index)]
                       (if (instance? String token)
                         ;; string token
                         (when (string/starts-with? actual-uri token)
                           (recur path-params (unchecked-add actual-index (count token)) (unchecked-inc token-index)))

          default-expr {:status 405
                        :headers {"Allow"        method-string
                                  "Content-Type" "text/plain"}
                        :body (str "405 Method not supported. Only " method-string " is supported.")}]
      `(if (identical? ~method-keyword (:request-method ~request))
         ~expr
         ~default-expr)))
