equal
deleted
inserted
replaced
4340 case (Cons x xs ys) |
4340 case (Cons x xs ys) |
4341 show ?case |
4341 show ?case |
4342 proof (cases "List.extract ((=) x) ys") |
4342 proof (cases "List.extract ((=) x) ys") |
4343 case None |
4343 case None |
4344 hence x: "x \<notin> set ys" by (simp add: extract_None_iff) |
4344 hence x: "x \<notin> set ys" by (simp add: extract_None_iff) |
4345 { |
4345 have nle: False if "mset (x # xs) \<subseteq># mset ys" |
4346 assume "mset (x # xs) \<subseteq># mset ys" |
4346 using set_mset_mono[OF that] x by simp |
4347 from set_mset_mono[OF this] x have False by simp |
|
4348 } note nle = this |
|
4349 moreover |
4347 moreover |
4350 { |
4348 have False if "mset (x # xs) \<subset># mset ys" |
4351 assume "mset (x # xs) \<subset># mset ys" |
4349 proof - |
4352 hence "mset (x # xs) \<subseteq># mset ys" by auto |
4350 from that have "mset (x # xs) \<subseteq># mset ys" by auto |
4353 from nle[OF this] have False . |
4351 from nle[OF this] show ?thesis . |
4354 } |
4352 qed |
4355 ultimately show ?thesis using None by auto |
4353 ultimately show ?thesis using None by auto |
4356 next |
4354 next |
4357 case (Some res) |
4355 case (Some res) |
4358 obtain ys1 y ys2 where res: "res = (ys1,y,ys2)" by (cases res, auto) |
4356 obtain ys1 y ys2 where res: "res = (ys1,y,ys2)" by (cases res, auto) |
4359 note Some = Some[unfolded res] |
4357 note Some = Some[unfolded res] |