mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-11 23:25:01 +00:00
refactor: move remaining language examples to fixture files
This commit is contained in:
parent
44ceb8f1a0
commit
8c218e9edc
6 changed files with 89 additions and 0 deletions
19
tests/fixtures/languages/ocaml/test.ml
vendored
Normal file
19
tests/fixtures/languages/ocaml/test.ml
vendored
Normal file
|
@ -0,0 +1,19 @@
|
|||
(* Module definition *)
|
||||
module Greeter = struct
|
||||
type person = {
|
||||
name: string;
|
||||
age: int
|
||||
}
|
||||
|
||||
let create_person name age =
|
||||
{name; age}
|
||||
|
||||
let greet person =
|
||||
Printf.printf "Hello, %s! You are %d years old.\n"
|
||||
person.name person.age
|
||||
end
|
||||
|
||||
(* Outside the module *)
|
||||
let () =
|
||||
let person = Greeter.create_person "Alice" 30 in
|
||||
Greeter.greet person
|
Loading…
Add table
Add a link
Reference in a new issue