Activity log for bug #1819015

Date Who What changed Old value New value Message
2019-03-07 15:10:56 Paul F. Dietz bug added bug
2019-03-07 15:49:41 Paul F. Dietz description One can get the definition of ordinary functios using FUNCTION-LAMBDA-EXPRESSION, but there is nothing similar for methods. Add a means for obtaining the source for a method from the method object, and also a means of replacing and restoring a method object for a generic function. It might be necessary to cheat a bit due to methods being defined in a lexical environment which may no longer be available, but that applies to the lambda expression from FUNCTION-LAMBDA-EXPRESSION as well. The use case for this is to do mutation testing on Common Lisp code. This would involve getting the definitions of functions and methods, mutating them, and seeing if the test suite kills the mutants. One can get the definition of ordinary functios using FUNCTION-LAMBDA-EXPRESSION (if the function was in a LOADed file, rather than from a fasl), but there is nothing similar for methods. Add a means for obtaining the source for a method from the method object, and also a means of replacing and restoring a method object for a generic function. It might be necessary to cheat a bit due to methods being defined in a lexical environment which may no longer be available, but that applies to the lambda expression from FUNCTION-LAMBDA-EXPRESSION as well. The use case for this is to do mutation testing on Common Lisp code. This would involve getting the definitions of functions and methods, mutating them, and seeing if the test suite kills the mutants.
2019-03-07 15:50:28 Paul F. Dietz description One can get the definition of ordinary functios using FUNCTION-LAMBDA-EXPRESSION (if the function was in a LOADed file, rather than from a fasl), but there is nothing similar for methods. Add a means for obtaining the source for a method from the method object, and also a means of replacing and restoring a method object for a generic function. It might be necessary to cheat a bit due to methods being defined in a lexical environment which may no longer be available, but that applies to the lambda expression from FUNCTION-LAMBDA-EXPRESSION as well. The use case for this is to do mutation testing on Common Lisp code. This would involve getting the definitions of functions and methods, mutating them, and seeing if the test suite kills the mutants. One can get the definition of ordinary functios using FUNCTION-LAMBDA-EXPRESSION (if the function was in a LOADed file, rather than from a fasl, or was defined by eval-ing a defun, or calling COMPILE on a lambda expression), but there is nothing similar for methods. Add a means for obtaining the source for a method from the method object, and also a means of replacing and restoring a method object for a generic function. It might be necessary to cheat a bit due to methods being defined in a lexical environment which may no longer be available, but that applies to the lambda expression from FUNCTION-LAMBDA-EXPRESSION as well. The use case for this is to do mutation testing on Common Lisp code. This would involve getting the definitions of functions and methods, mutating them, and seeing if the test suite kills the mutants.